diff options
author | Mau Magnaguagno <maumagnaguagno@gmail.com> | 2022-12-19 12:44:23 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-19 10:44:23 -0500 |
commit | b2f53dccbedd9f399bc4668eb02f26b2eafa6f5c (patch) | |
tree | 2773dfd6ff6a035c9e8ba4d8e055cb2510663364 | |
parent | 1482f0649e303c8bf11281268d3e1e6e2370c093 (diff) | |
download | ruby-b2f53dccbedd9f399bc4668eb02f26b2eafa6f5c.tar.gz |
YJIT: skip map in print_sorted_exit_counts (#6954)
Array#sum accepts a block.
-rw-r--r-- | yjit.rb | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -303,7 +303,7 @@ module RubyVM::YJIT total_exits = total_exit_count(stats) if total_exits > 0 - top_n_total = exits.map { |name, count| count }.sum + top_n_total = exits.sum { |name, count| count } top_n_exit_pct = 100.0 * top_n_total / total_exits $stderr.puts "Top-#{exits.size} most frequent exit ops (#{"%.1f" % top_n_exit_pct}% of exits):" |