summaryrefslogtreecommitdiff
path: root/rjit_c.rb
diff options
context:
space:
mode:
authorTakashi Kokubun <takashikkbn@gmail.com>2023-12-18 23:49:54 -0800
committerTakashi Kokubun <takashikkbn@gmail.com>2023-12-18 23:55:40 -0800
commiteb872d17524f299bdd023f005da38ffcddffa90a (patch)
tree5c3b6356ac5b7e9602ec4a436d300c6771e5924b /rjit_c.rb
parentdee45ac231afd02797640cb335d86550aa620cbe (diff)
RJIT: Share rb_vm_insns_count for vm_insns_count
Diffstat (limited to 'rjit_c.rb')
-rw-r--r--rjit_c.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/rjit_c.rb b/rjit_c.rb
index 4606352a96..ee5759a08d 100644
--- a/rjit_c.rb
+++ b/rjit_c.rb
@@ -512,6 +512,10 @@ module RubyVM::RJIT # :nodoc: all
Primitive.cexpr! %q{ SIZET2NUM(rb_rjit_global_events) }
end
+ def C.rb_vm_insns_count
+ Primitive.cexpr! %q{ SIZET2NUM(rb_vm_insns_count) }
+ end
+
def C.rb_ary_clear
Primitive.cexpr! %q{ SIZET2NUM((size_t)rb_ary_clear) }
end
@@ -1335,7 +1339,6 @@ module RubyVM::RJIT # :nodoc: all
def C.rb_rjit_runtime_counters
@rb_rjit_runtime_counters ||= CType::Struct.new(
"rb_rjit_runtime_counters", Primitive.cexpr!("SIZEOF(struct rb_rjit_runtime_counters)"),
- vm_insns_count: [CType::Immediate.parse("size_t"), Primitive.cexpr!("OFFSETOF((*((struct rb_rjit_runtime_counters *)NULL)), vm_insns_count)")],
rjit_insns_count: [CType::Immediate.parse("size_t"), Primitive.cexpr!("OFFSETOF((*((struct rb_rjit_runtime_counters *)NULL)), rjit_insns_count)")],
send_args_splat_kw_splat: [CType::Immediate.parse("size_t"), Primitive.cexpr!("OFFSETOF((*((struct rb_rjit_runtime_counters *)NULL)), send_args_splat_kw_splat)")],
send_args_splat: [CType::Immediate.parse("size_t"), Primitive.cexpr!("OFFSETOF((*((struct rb_rjit_runtime_counters *)NULL)), send_args_splat)")],