summaryrefslogtreecommitdiff
path: root/tool
diff options
context:
space:
mode:
authorKoichi Sasada <ko1@atdot.net>2019-07-03 03:37:25 +0900
committerKoichi Sasada <ko1@atdot.net>2019-07-03 03:37:25 +0900
commit712a66b0741605f5b2db670a292b9bb352f8a716 (patch)
treea15f199e0bcc85b5f570011737d3305381fbd43d /tool
parentc07165be1d2bccc9e1c67a90d16259a9c929b56d (diff)
Revert "Avoid corrupting VM stack on inlined setlocal"
This reverts commit ea30dd702512ff9df34fe8c71c825f8f901bf5b1. because it fails when VM_CHECK_MODE=1.
Diffstat (limited to 'tool')
-rw-r--r--tool/ruby_vm/views/_mjit_compile_send.erb5
1 files changed, 0 insertions, 5 deletions
diff --git a/tool/ruby_vm/views/_mjit_compile_send.erb b/tool/ruby_vm/views/_mjit_compile_send.erb
index 3db1386aca..da7e96581b 100644
--- a/tool/ruby_vm/views/_mjit_compile_send.erb
+++ b/tool/ruby_vm/views/_mjit_compile_send.erb
@@ -46,15 +46,10 @@
% # JIT: If ISeq is inlinable, call the inlined method without pushing a frame.
if (status->inlined_iseqs != NULL && status->inlined_iseqs[pos] == iseq->body) {
- // TODO: consider using C variables for Ruby variables to simplify cfp->ep manipulation
fprintf(f, " {\n");
fprintf(f, " VALUE orig_self = reg_cfp->self;\n");
- fprintf(f, " VALUE orig_ep = reg_cfp->ep;\n");
fprintf(f, " reg_cfp->self = stack[%d];\n", b->stack_size - argc - 1);
- fprintf(f, " reg_cfp->ep = reg_cfp->sp + %d + 2;\n", iseq->body->local_table_size - iseq->body->param.size); // simulate `vm_push_frame`'s local_size and 2 increments
- fprintf(f, " ((VALUE *)reg_cfp->ep)[VM_ENV_DATA_INDEX_ENV] = ((VALUE *)orig_ep)[VM_ENV_DATA_INDEX_ENV];\n"); // `vm_env_write_slowpath` checks this value
fprintf(f, " stack[%d] = _mjit_inlined_%d(ec, reg_cfp, orig_self, original_iseq);\n", b->stack_size - argc - 1, pos);
- fprintf(f, " reg_cfp->ep = orig_ep;\n");
fprintf(f, " reg_cfp->self = orig_self;\n");
fprintf(f, " }\n");
}