diff options
author | Takashi Kokubun <takashikkbn@gmail.com> | 2022-09-06 12:33:51 +0900 |
---|---|---|
committer | Takashi Kokubun <takashikkbn@gmail.com> | 2022-09-06 15:45:10 +0900 |
commit | 5b3bd91fcba7224e9ece54c862dc96461cf4bf79 (patch) | |
tree | c5d0e51cd54b18cb9045b746113bb65e3b89262a /mjit.h | |
parent | f6925fab853ffc1872038f33d93e4e5c5379b4db (diff) |
Add an option to lazily boot MJIT for experiments
You may use `RUBYOPT=--mjit=pause irb` to play with RubyVM::MJIT::C,
control the boot timing of MJIT, or customize the implementation while
paused. It's an undocumented feature for such experiments.
Diffstat (limited to 'mjit.h')
-rw-r--r-- | mjit.h | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -49,7 +49,7 @@ struct mjit_options { bool debug; // Add arbitrary cflags. char* debug_flags; - // If not 0, all ISeqs are synchronously compiled. For testing. + // If true, all ISeqs are synchronously compiled. For testing. bool wait; // Number of calls to trigger JIT compilation. For testing. unsigned int min_calls; @@ -59,6 +59,8 @@ struct mjit_options { // Maximal permitted number of iseq JIT codes in a MJIT memory // cache. int max_cache_size; + // [experimental] If true, do not start MJIT until MJIT.resume is called. + bool pause; }; // State of optimization switches |