pyroscope icon indicating copy to clipboard operation
pyroscope copied to clipboard

Show functions % of total [units] in Table

Open Rperry2174 opened this issue 2 years ago • 0 comments

Currently when seeing the flamegraph, you can see certain functions % of total [unit of time]. However, if that function shows up multiple times in different parts of the flamegraph, there is now way to see that functions total share of [unit].

we should add a tooltip to the table which shows the value in the table divided by the total value from the flamegraph which represents the aggregate share of [unit]

image

i.e. here this function takes up 3.99 minutes and the flamegraph shows a total of 17.85 minutes so we should show a tooltip that shows Share of total cpu: 22% (3.99 / 17.85 = 22%)

Note this is also tied to #337 This will possibly break for recursive functions because it can be > 100% and should also be addressed similar to how we started to fix in #1024

We should also make the tooltip more "Pyroscope" themed instead of this generic color. Maybe something similar to the tooltip from the flamegraph, which should show up when hovering over any part of this row:

table_tooltip_mockup_00-01 Note: text is not to scale -- we should use text size from the current tooltip, but just to get the idea of what elements should be where

Implementation details / other thoughts

  • Lets not add a tooltip to the diff view table for now -- we should come up with a totally different set of information fo the diff view table
  • Let's try to reuse the existing tooltip component, but it should be configurable such that we can either include or not include both the header and the footer

Rperry2174 avatar Jul 18 '22 18:07 Rperry2174