[前][次][番号順一覧][スレッド一覧]

ruby-changes:69146

From: Maxime <ko1@a...>
Date: Thu, 21 Oct 2021 08:20:59 +0900 (JST)
Subject: [ruby-changes:69146] 70c5bbf84b (master): Fix counter names for getblockparamproxy. Print in --yjit-stats.

https://git.ruby-lang.org/ruby.git/commit/?id=70c5bbf84b

From 70c5bbf84b569d293c0162c084c99d2ca609d9be Mon Sep 17 00:00:00 2001
From: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@s...>
Date: Mon, 4 Oct 2021 11:26:28 -0400
Subject: Fix counter names for getblockparamproxy. Print in --yjit-stats.

---
 yjit.rb        | 1 +
 yjit_codegen.c | 4 ++--
 yjit_iface.h   | 4 ++--
 3 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/yjit.rb b/yjit.rb
index 29a8d39d27..79511685d1 100644
--- a/yjit.rb
+++ b/yjit.rb
@@ -155,6 +155,7 @@ module YJIT https://github.com/ruby/ruby/blob/trunk/yjit.rb#L155
       print_counters(stats, prefix: 'send_', prompt: 'method call exit reasons: ')
       print_counters(stats, prefix: 'invokesuper_', prompt: 'invokesuper exit reasons: ')
       print_counters(stats, prefix: 'leave_', prompt: 'leave exit reasons: ')
+      print_counters(stats, prefix: 'gbpp_', prompt: 'getblockparamproxy exit reasons: ')
       print_counters(stats, prefix: 'getivar_', prompt: 'getinstancevariable exit reasons:')
       print_counters(stats, prefix: 'setivar_', prompt: 'setinstancevariable exit reasons:')
       print_counters(stats, prefix: 'oaref_', prompt: 'opt_aref exit reasons: ')
diff --git a/yjit_codegen.c b/yjit_codegen.c
index f6973b5a81..80270e64d4 100644
--- a/yjit_codegen.c
+++ b/yjit_codegen.c
@@ -4217,7 +4217,7 @@ gen_getblockparamproxy(jitstate_t *jit, ctx_t *ctx, codeblock_t *cb) https://github.com/ruby/ruby/blob/trunk/yjit_codegen.c#L4217
 
     // Bail when VM_ENV_FLAGS(ep, VM_FRAME_FLAG_MODIFIED_BLOCK_PARAM) is non zero
     test(cb, mem_opnd(64, REG0, SIZEOF_VALUE * VM_ENV_DATA_INDEX_FLAGS), imm_opnd(VM_FRAME_FLAG_MODIFIED_BLOCK_PARAM));
-    jnz_ptr(cb, COUNTED_EXIT(side_exit, block_param_is_modified));
+    jnz_ptr(cb, COUNTED_EXIT(side_exit, gbpp_block_param_modified));
 
     // Load the block handler for the current frame
     // note, VM_ASSERT(VM_ENV_LOCAL_P(ep))
@@ -4228,7 +4228,7 @@ gen_getblockparamproxy(jitstate_t *jit, ctx_t *ctx, codeblock_t *cb) https://github.com/ruby/ruby/blob/trunk/yjit_codegen.c#L4228
 
     // Bail unless VM_BH_ISEQ_BLOCK_P(bh). This also checks for null.
     cmp(cb, REG0_8, imm_opnd(0x1));
-    jnz_ptr(cb, COUNTED_EXIT(side_exit, block_handler_is_not_iseq));
+    jnz_ptr(cb, COUNTED_EXIT(side_exit, gbpp_block_handler_not_iseq));
 
     // Push rb_block_param_proxy. It's a root, so no need to use jit_mov_gc_ptr.
     mov(cb, REG0, const_ptr_opnd((void *)rb_block_param_proxy));
diff --git a/yjit_iface.h b/yjit_iface.h
index 639c728c0c..9eef02c2d9 100644
--- a/yjit_iface.h
+++ b/yjit_iface.h
@@ -107,8 +107,8 @@ YJIT_DECLARE_COUNTERS( https://github.com/ruby/ruby/blob/trunk/yjit_iface.h#L107
     expandarray_not_array,
     expandarray_rhs_too_small,
 
-    block_param_is_modified,
-    block_handler_is_not_iseq,
+    gbpp_block_param_modified,
+    gbpp_block_handler_not_iseq,
 
     // Member with known name for iterating over counters
     last_member
-- 
cgit v1.2.1


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]