-
-
Notifications
You must be signed in to change notification settings - Fork 19
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
Make the language JIT compiled (part 1) #106
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…on debug level 2
…and a function to debug the registers inside JIT
… 2 additional debug levels
…HR`, and `RSHI` opcodes to JIT abstraction layer
…nstructions from the Dynamic Instructions
…ore floating-point registers)
…` opcodes Also rename `PRNT` opcode to `DYN_PRINT`.
…DYN_LER` and `DYN_LNOT` opcodes and pass the operator tests
… and implement function calls
…nt the basics of a function call
…the dictionaries
… `DYN_DICT_KEY_SEARCH` opcodes
mertyildiran
added
feature request
New feature or request
performance
Performance issues or improvements
labels
Aug 31, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Related to #105
This PR rewrites the compiler, introduces a JIT abstraction layer (IR) and rewrites the code under
vm
directory to compile the IR into machine code by using MyJIT as the JIT backend.This PR;
compiler_
prefixed GitHub workflows.0
: No debugging1
: Print AST and quit2
: Print AST, JIT Abstraction Layer and quit3
: Print AST, JIT Abstraction Layer,JIT_DEBUG_OPS
andJIT_DEBUG_CODE
4
: Print AST, JIT Abstraction Layer,JIT_DEBUG_OPS
,JIT_DEBUG_CODE
andJIT_DEBUG_COMBINED
5
: Print AST, JIT Abstraction Layer,JIT_DEBUG_OPS
,JIT_DEBUG_CODE
and the values in the registers, in program runtime6
: Print AST, JIT Abstraction Layer,JIT_DEBUG_COMBINED
and the values in the registers, in program runtimenumber
,del
,decision
,spell
,echo
,boolean
,exit_var
,exit_int
,pretty
,string
,dict
,print
,underscore
,samedirlib
,syntax_error
,nonewline
,immutability
,quit
,operator
,list
,exit
andany
.myjit
as a Git submodule.Makefile
to separate compilation and linking.Example of JIT Abstraction Layer,
JIT_DEBUG_OPS
andJIT_DEBUG_CODE
dev.kaos
:Once it's run with
chaos -d 3 dev.kaos
it prints: