Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JIT: Added Code.lookup function and various supporting code changes #4339

Merged
merged 8 commits into from
Oct 5, 2023

Conversation

dolio
Copy link
Contributor

@dolio dolio commented Oct 5, 2023

This PR contains updates related to looking up code at runtime

  • Added a code cache in the unison/data module that associates the term links with their intermediate code.
  • Added a macro for defining termlinks for builtin functions, for builtins that are implemented direclty in scheme.
  • Declared termlinks for directly implemented builtins
  • Nullary unison data constructors have been changed to not be procedures, so various replacements like:
    (unison-optional-none) ==> unison-optional-none
  • Implemented code lookup builtin/primop
  • Modified the serialized tests to check code lookup of dynamically added code

I'll add some tests that look up statically generated code. Right now the tests only look up code that is added to the cache dynamically, and that's an almost completely different code path.

dolio added 4 commits October 4, 2023 23:11
- Added a code cache in the unison/data module that associates the
  term links with their intermediate code.
- Added a macro for defining termlinks for builtin functions, for
  builtins that are implemented direclty in scheme.
- Declared termlinks for directly implemented builtins
- Nullary unison data constructors have been changed to not be
  procedures, so various replacements like:
    (unison-optional-none) ==> unison-optional-none
- Implemented code lookup builtin/primop
- Makes sure the code that is added to the cache as part of the test can
  be looked back up, and is equal to what was added to the cache.
@pchiusano pchiusano changed the title Various changes related to code lookup JIT: Added Code.lookup function and various supporting code changes Oct 5, 2023
@pchiusano pchiusano merged commit f15816c into trunk Oct 5, 2023
6 checks passed
@pchiusano pchiusano deleted the topic/scheme-code-lookup branch October 5, 2023 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants