Skip to content

Fix the SFI-reading heuristic for Node v24+#270

Merged
umanwizard merged 2 commits into
mainfrom
fix-sfi-heuristic
May 14, 2026
Merged

Fix the SFI-reading heuristic for Node v24+#270
umanwizard merged 2 commits into
mainfrom
fix-sfi-heuristic

Conversation

@umanwizard
Copy link
Copy Markdown
Collaborator

This, along with #269 , contributes to fixing parca-dev/parca-agent#3180 .

It should be clear what is going on from the comments; if not, I can flesh them out.

I think we can close parca-dev/parca-agent#3180 once both of these lands since the behavior is the same as in v20, but since some frames are still symbolized as line "0" in Manoj's test program, I want to investigate those before adding a corresponding test.

@umanwizard umanwizard requested review from brancz and gnurizen May 13, 2026 23:56
@gnurizen
Copy link
Copy Markdown
Collaborator

Probably need to fix the failing coredump test, looks like maybe you correctly fixed the line number? But someone added this test w/o adding hello3.js to coredump/testsources/node we should bring that up upstream.

@umanwizard
Copy link
Copy Markdown
Collaborator Author

It looks like I'm the one who added that coredump test... unfortunately I didn't save the corresponding hello3.js.

@gnurizen
Copy link
Copy Markdown
Collaborator

Could try running strings on the coredump and fishing it out!

@umanwizard
Copy link
Copy Markdown
Collaborator Author

That's a great idea, and it worked.

Here's the source code:

function bar(a, s) {
        a(s)
}

function foo() {
        bar(a, "Hello world!")
}

a = console.log
while (1) {
        foo()
}

The symbolization of the function names is weird, probably some inlining or TCO going on. But indeed the work is going on on line 1, not line 0, so I think the change makes sense.

@umanwizard umanwizard merged commit 536dfad into main May 14, 2026
52 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

V8 user-code frames report line=0, column=0 on Node 22+

2 participants