diff options
| author | Shannon Skipper <shannonskipper@gmail.com> | 2025-11-16 09:01:50 -0800 |
|---|---|---|
| committer | Alan Wu <XrXr@users.noreply.github.com> | 2025-11-18 16:57:47 -0500 |
| commit | cbe65ebbc3f2b77316d50b94e84df1c00822d0f2 (patch) | |
| tree | e7b4a8673913c011777d24d12308195990f3a38b | |
| parent | 656600371239a4a62e7a26e148af70e98d0fa979 (diff) | |
ZJIT: Skip empty counter sections in stats
| -rw-r--r-- | zjit.rb | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -297,7 +297,7 @@ class << RubyVM::ZJIT def print_counters_with_prefix(buf:, stats:, prefix:, prompt:, limit: nil) counters = stats.select { |key, value| key.start_with?(prefix) && value > 0 } - return if stats.empty? + return if counters.empty? counters.transform_keys! { |key| key.to_s.delete_prefix(prefix) } key_pad = counters.keys.map(&:size).max |
