profiler icon indicating copy to clipboard operation
profiler copied to clipboard

Flame graph should display when the call tree is inverted

Open gregtatum opened this issue 3 years ago • 0 comments

I've been profiling things lately where the inverted call tree is really helpful, especially as these highlight when heavy allocations are causing slowdowns.

I would like to toggle between the inverted call tree and the flame graph to see what is going on. This could be accomplished through a selector.

Pseudo-code:

export const getInvertCallstack: Selector<boolean> = (state) => {
  switch (tabSlug) {
    case "flame-graph":
      return false;
    default:
      return getProfileSpecificState(state).invertCallstack;
  }
}

I'm not sure if there are realistic plans to support the inverted view in the flame graph due to perf reasons, but this would get rid of the annoying switching button.

gregtatum avatar Mar 29 '22 16:03 gregtatum