summaryrefslogtreecommitdiff
path: root/tool/ruby_vm
diff options
context:
space:
mode:
authorTakashi Kokubun <takashikkbn@gmail.com>2023-02-10 17:41:59 -0800
committerTakashi Kokubun <takashikkbn@gmail.com>2023-03-05 22:41:35 -0800
commit14acf9b0a3c5c06cd8a1bf60c929b25c6e7fee66 (patch)
treec85aad1e2752226ef9d1d60b3d70e09547903407 /tool/ruby_vm
parentb30392f8ab16b10074a7362f187850e6898a20bb (diff)
downloadruby-14acf9b0a3c5c06cd8a1bf60c929b25c6e7fee66.tar.gz
Decode trace insns properly
Diffstat (limited to 'tool/ruby_vm')
-rw-r--r--tool/ruby_vm/views/lib/ruby_vm/mjit/instruction.rb.erb3
1 files changed, 2 insertions, 1 deletions
diff --git a/tool/ruby_vm/views/lib/ruby_vm/mjit/instruction.rb.erb b/tool/ruby_vm/views/lib/ruby_vm/mjit/instruction.rb.erb
index 38b9c1f92e..16c10a9928 100644
--- a/tool/ruby_vm/views/lib/ruby_vm/mjit/instruction.rb.erb
+++ b/tool/ruby_vm/views/lib/ruby_vm/mjit/instruction.rb.erb
@@ -16,11 +16,11 @@ module RubyVM::MJIT # :nodoc: all
INSNS = {
% RubyVM::Instructions.each_with_index do |insn, i|
-% next if insn.name.start_with?('trace_')
<%= i %> => Instruction.new(
name: :<%= insn.name %>,
bin: <%= i %>, # BIN(<%= insn.name %>)
len: <%= insn.width %>, # insn_len
+% unless insn.name.start_with?('trace_')
expr: <<-EXPR,
<%= insn.expr.expr.dump.sub(/\A"/, '').sub(/"\z/, '').gsub(/\\n/, "\n").gsub(/\\t/, ' ' * 8) %>
EXPR
@@ -32,6 +32,7 @@ module RubyVM::MJIT # :nodoc: all
always_leaf?: <%= insn.always_leaf? %>,
leaf_without_check_ints?: <%= insn.leaf_without_check_ints? %>,
handles_sp?: <%= insn.handles_sp? %>,
+% end
),
% end
}