summaryrefslogtreecommitdiff
path: root/vm.c
diff options
context:
space:
mode:
authorMaxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com>2023-03-28 15:21:19 -0400
committerGitHub <noreply@github.com>2023-03-28 15:21:19 -0400
commit39a34694a0e33e18b4ac6e43cb8042e2d818ecd4 (patch)
tree3d70bdeb6fdf015b95d3306130eb52bbff0802a0 /vm.c
parent2f8a598dc598b4faaab5d8fd4740811d52fece96 (diff)
downloadruby-39a34694a0e33e18b4ac6e43cb8042e2d818ecd4.tar.gz
YJIT: Add `--yjit-pause` and `RubyVM::YJIT.resume` (#7609)
* YJIT: Add --yjit-pause and RubyVM::YJIT.resume This allows booting YJIT in a suspended state. We chose to add a new command line option as opposed to simply allowing YJIT.resume to work without any command line option because it allows for combining with YJIT tuning command line options. It also simpifies implementation. Paired with Kokubun and Maxime. * Update yjit.rb Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com> --------- Co-authored-by: Alan Wu <XrXr@users.noreply.github.com> Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com>
Diffstat (limited to 'vm.c')
-rw-r--r--vm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/vm.c b/vm.c
index 11fc54095b..31725ae2d0 100644
--- a/vm.c
+++ b/vm.c
@@ -376,7 +376,7 @@ jit_compile(rb_execution_context_t *ec)
// Increment the ISEQ's call counter
const rb_iseq_t *iseq = ec->cfp->iseq;
struct rb_iseq_constant_body *body = ISEQ_BODY(iseq);
- bool yjit_enabled = rb_yjit_enabled_p();
+ bool yjit_enabled = rb_yjit_compile_new_iseqs();
if (yjit_enabled || rb_rjit_call_p) {
body->total_calls++;
}