Repository navigation
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6419 +/- ##
=======================================
Coverage 84.95% 84.96%
=======================================
Files 359 359
Lines 39137 39170 +33
Branches 11091 11105 +14
=======================================
+ Hits 33249 33280 +31
- Misses 5451 5453 +2
Partials 437 437 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
fatadel
reviewed
Nov 6, 2026
fatadel
left a comment
Contributor
There was a problem hiding this comment.
Is the inverted flame graph planned for a follow-up or was it supposed to be handled here? (same-name siblings are still ordered by func index there)
fatadel
reviewed
Nov 6, 2026
Contributor
Author
Oh I forgot about the inverted flame graph. I'll fix that in this PR. |
The flame graph ordered siblings by function name only. Siblings with the same name kept the order in which they appear in the call node table, which depends on the stack table. Two similar profiles could therefore show the same functions in opposite orders. Example: in the JS-only flame graph of https://share.firefox.dev/4jy20z8 vs https://share.firefox.dev/4k1tYTW, the call node for callHook in the stack below has two children named "view": view [../../src/components/Controls.js:9:5] callHook [../../node_modules/mithril/render/render.js:34:11] updateComponent [../../node_modules/mithril/render/render.js:462:11] updateNode [../../node_modules/mithril/render/render.js:396:11] updateNodes [../../node_modules/mithril/render/render.js:270:11] updateElement [../../node_modules/mithril/render/render.js:451:11] Both view functions come from the same bundle, so they have the same name and the same file name. The two profiles showed them in opposite orders. Siblings with the same function name are now compared by: 1. The generated file name. 2. The original (source-mapped) file name. 3. The line, then the column, where the function starts. This uses the original location if there is one, and the generated location otherwise. 4. The resource name, for example the library of a native function. 5. The function index, so that two different functions never compare equal. The inverted flame graph uses the same order. It previously ordered siblings with the same name by function index only. The new makeFlameGraphFuncComparator function creates this comparison function. computeFlameGraphRows and getInvertedFlameGraphTiming now take the comparison function instead of the FuncTable and the StringTable. bisectionRightByStrKey is replaced with bisectionRightBy, which takes a comparison function.
mstange
force-pushed
the
push-kypzpsmwrtom
branch
from
November 6, 2026 19:44
e4e3447 to
3801343
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Main | Deploy preview
Compare these flame graphs: https://share.firefox.dev/4jy20z8 vs https://share.firefox.dev/4k1tYTW
There are two
viewcall nodes with the same parent which swap positions in the two views. That's because they currently do not have a defined order. This PR fixes that.