diff --git a/champ.rb b/champ.rb index e69f276..a28f48c 100755 --- a/champ.rb +++ b/champ.rb @@ -622,7 +622,9 @@ class Champ all_nodes.each do |node| label = @label_for_pc[node] || sprintf('0x%04x', node) label = "#{label}" - label += "
#{@cycles_per_function[node]}" + if @calls_per_function[node] && @cycles_per_function[node] + label += "
#{@cycles_per_function[node] / @calls_per_function[node]}" + end io.puts " _#{node} [label = <#{label}>];" end @call_graph_counts.each_pair do |key, entries| diff --git a/doc/screenshot.png b/doc/screenshot.png index b4b839f..8ce4da1 100644 Binary files a/doc/screenshot.png and b/doc/screenshot.png differ