You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The question is, why is this in reverse order? Given time in standard charts virtually always goes from left to right, you would expect the ordering in the flamechart to match that of the input file and go from left to right, i.e. "a, b, c, this, is, a, test" in this example.
I can easily enough emit my input lines in reverse order, but this seems wrong, and will confuse anyone who uses the feature for the first time.
The text was updated successfully, but these errors were encountered:
I believe this was done purely to match the behavior of the original flamegraph implementation. @AnderEnder may be able to shed more light though, as they originally contributed #125.
As for why the original flamegraph does this, my guess would be it's because of scrolling. By having the most recent time to the left, you can see what last happened, and thus is most likely to be relevant, without having to scroll far right. Whether that's a good reason I'm not so sure, but 🤷 I'm not opposed to changing this either if we decide non-reversed just overall makes more sense.
Consider the following profiling report:
Per https://docs.rs/inferno/latest/inferno/flamegraph/struct.Options.html#structfield.flame_chart, the input will be "reversed". And indeed, the resulting SVG has frames in the reverse order "test, a, is, this, c, b, a":
The question is, why is this in reverse order? Given time in standard charts virtually always goes from left to right, you would expect the ordering in the flamechart to match that of the input file and go from left to right, i.e. "a, b, c, this, is, a, test" in this example.
I can easily enough emit my input lines in reverse order, but this seems wrong, and will confuse anyone who uses the feature for the first time.
The text was updated successfully, but these errors were encountered: