summaryrefslogtreecommitdiff
path: root/yjit.rb
diff options
context:
space:
mode:
authorMaxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com>2023-01-18 11:08:55 -0500
committerGitHub <noreply@github.com>2023-01-18 11:08:55 -0500
commitcd97976328204263c464cf6846e9bafe6424da15 (patch)
tree5b9d2268be9f8e6927b9699b570d9b01dbf9e859 /yjit.rb
parent03f5db01e6be9b522d6fbbfb54f07d168c1a3a34 (diff)
downloadruby-cd97976328204263c464cf6846e9bafe6424da15.tar.gz
Add stats so we can keep track of x86 rel32 vs register calls (#7142)
* Add stats so we can keep track of x86 rel32 vs register calls To know if we get that "prime real estate" as Alan put it. * Fix bug pointed by Alan
Diffstat (limited to 'yjit.rb')
-rw-r--r--yjit.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/yjit.rb b/yjit.rb
index 062784f564..0079d8d895 100644
--- a/yjit.rb
+++ b/yjit.rb
@@ -253,6 +253,11 @@ module RubyVM::YJIT
# Number of failed compiler invocations
compilation_failure = stats[:compilation_failure]
+ if stats[:x86_call_rel32] != 0 || stats[:x86_call_reg] != 0
+ $stderr.puts "x86_call_rel32: " + ("%10d" % stats[:x86_call_rel32])
+ $stderr.puts "x86_call_reg: " + ("%10d" % stats[:x86_call_reg])
+ end
+
$stderr.puts "bindings_allocations: " + ("%10d" % stats[:binding_allocations])
$stderr.puts "bindings_set: " + ("%10d" % stats[:binding_set])
$stderr.puts "compilation_failure: " + ("%10d" % compilation_failure) if compilation_failure != 0