summaryrefslogtreecommitdiff
path: root/tool
diff options
context:
space:
mode:
authorTakashi Kokubun <takashikkbn@gmail.com>2019-07-14 18:04:14 +0900
committerTakashi Kokubun <takashikkbn@gmail.com>2019-07-14 18:04:19 +0900
commitd30d404bc4b848f84959799b543de4bdbd8eef2b (patch)
tree4b89685b73c05fae3d7d8013efaed8be1dbea193 /tool
parent043e3d2cdc02a3571e3e2c3b9252a65d3c049740 (diff)
MJIT Support for getblockparamproxy
Diffstat (limited to 'tool')
-rw-r--r--tool/ruby_vm/views/_mjit_compile_insn_body.erb3
-rw-r--r--tool/ruby_vm/views/mjit_compile.inc.erb1
2 files changed, 3 insertions, 1 deletions
diff --git a/tool/ruby_vm/views/_mjit_compile_insn_body.erb b/tool/ruby_vm/views/_mjit_compile_insn_body.erb
index 7035779221..a2a750fbdc 100644
--- a/tool/ruby_vm/views/_mjit_compile_insn_body.erb
+++ b/tool/ruby_vm/views/_mjit_compile_insn_body.erb
@@ -81,6 +81,9 @@
fprintf(f, " reg_cfp->pc = original_body_iseq + %d;\n", pos);
fprintf(f, " RB_DEBUG_COUNTER_INC(mjit_cancel_opt_insn);\n");
fprintf(f, " goto cancel;\n");
+% when /\A(?<prefix>.+\b)INSN_LABEL\((?<name>[^)]+)\)(?<suffix>.+)\z/m
+% prefix, name, suffix = Regexp.last_match[:prefix], Regexp.last_match[:name], Regexp.last_match[:suffix]
+ fprintf(f, " <%= prefix.gsub(/\t/, ' ' * 8) %>INSN_LABEL(<%= name %>_%d)<%= suffix.sub(/\n/, '\n') %>", pos);
% else
% if insn.handles_sp?
% # If insn.handles_sp? is true, cfp->sp might be changed inside insns (like vm_caller_setup_arg_block)
diff --git a/tool/ruby_vm/views/mjit_compile.inc.erb b/tool/ruby_vm/views/mjit_compile.inc.erb
index 1812dabf4a..d9092a756d 100644
--- a/tool/ruby_vm/views/mjit_compile.inc.erb
+++ b/tool/ruby_vm/views/mjit_compile.inc.erb
@@ -16,7 +16,6 @@
} -%>
%
% unsupported_insns = [
-% 'getblockparamproxy', # TODO: support this
% 'defineclass', # low priority
% 'opt_call_c_function', # low priority
% ]