Skip to content

Commit

Permalink
Use rb_yjit_threshold_hit for jit_compile_exception
Browse files Browse the repository at this point in the history
  • Loading branch information
k0kubun committed Sep 14, 2023
1 parent 6886ba4 commit 1c0d2a2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vm.c
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ jit_compile_exception(rb_execution_context_t *ec)
// Increment the ISEQ's call counter and trigger JIT compilation if not compiled
if (body->jit_exception == NULL) {
body->jit_exception_calls++;
if (body->jit_exception_calls == rb_yjit_call_threshold()) {
if (rb_yjit_threshold_hit(iseq, body->jit_exception_calls)) {
rb_yjit_compile_iseq(iseq, ec, true);
}
}
Expand Down

0 comments on commit 1c0d2a2

Please sign in to comment.