summaryrefslogtreecommitdiff
path: root/tool
diff options
context:
space:
mode:
Diffstat (limited to 'tool')
-rw-r--r--tool/ruby_vm/views/_mjit_compile_send.erb8
1 files changed, 7 insertions, 1 deletions
diff --git a/tool/ruby_vm/views/_mjit_compile_send.erb b/tool/ruby_vm/views/_mjit_compile_send.erb
index e2d24bd3f7..41a77189d9 100644
--- a/tool/ruby_vm/views/_mjit_compile_send.erb
+++ b/tool/ruby_vm/views/_mjit_compile_send.erb
@@ -65,7 +65,13 @@
fprintf(f, " v = vm_exec(ec, TRUE);\n");
}
else {
- fprintf(f, " if ((v = mjit_exec(ec)) == Qundef) {\n");
+ if (status->iseq_for_pos != NULL && status->iseq_for_pos[pos] == iseq->body) {
+ fprintf(f, " v = _mjit_inlined_%d(ec, ec->cfp);\n", pos);
+ }
+ else {
+ fprintf(f, " v = mjit_exec(ec);\n");
+ }
+ fprintf(f, " if (v == Qundef) {\n");
fprintf(f, " VM_ENV_FLAGS_SET(ec->cfp->ep, VM_FRAME_FLAG_FINISH);\n"); /* This is vm_call0_body's code after vm_call_iseq_setup */
fprintf(f, " v = vm_exec(ec, FALSE);\n");
fprintf(f, " }\n");