diff options
author | Maxime Chevalier-Boisvert <maximechevalierb@gmail.com> | 2021-02-26 11:57:59 -0500 |
---|---|---|
committer | Alan Wu <XrXr@users.noreply.github.com> | 2021-10-20 18:19:30 -0400 |
commit | 6f437d5b30355070f15921a421c5c4ea7a3147d8 (patch) | |
tree | f8df0d11c85c494a067ad4732c0e15ae794f3553 /doc | |
parent | 0888d9c9d52c7021ac39f712b0111fe43dce81b0 (diff) |
Update ujit.md
Diffstat (limited to 'doc')
-rw-r--r-- | doc/ujit.md | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/doc/ujit.md b/doc/ujit.md index 554b433fa4..6e6b189e9d 100644 --- a/doc/ujit.md +++ b/doc/ujit.md @@ -1,7 +1,7 @@ MicroJIT (uJIT) =============== -**DISCLAIMER: Please note that this project is in early stages of development. It is very much a work in progress, it may cause your software to crash, and current performance results are likely to leave you feeling unimpressed.** +**DISCLAIMER: Please note that this project is in early stages of development. It is very much a work in progress, it may cause your software to crash, and current performance results are likely to leave you feeling underwhelmed.** MicroJIT is a lightweight, minimalistic Ruby JIT built inside the CRuby/MRI binary. It lazily compiles code using a Basic Block Versioning (BBV) architecture. The target use case is that of servers running @@ -49,15 +49,17 @@ by using the `chruby` tool: ``` chruby ruby-microjit -ruby <options> +ruby myscript.rb ``` You can dump statistics about compilation and execution by running uJIT with the `--ujit-stats` command-line option: ``` -./miniruby --ujit-stats <options> +./miniruby --ujit-stats myscript.rb ``` +The machine code generated for a given method can be printed by adding `puts UJIT.disasm(method(:method_name))` to a Ruby script. Note that no code will be generated if the method is not compiled. + ## Source Code Organization The uJIT source code is divided between: |