Skip to content

Conversation

@manojVivek
Copy link
Contributor

@manojVivek manojVivek commented Dec 10, 2025

Resolves #823

Contains:

  • Extracting column info in v8 profiler
  • Passing the extracted column info with the sample frames

@manojVivek manojVivek requested review from a team as code owners December 10, 2025 09:39
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Dec 10, 2025

CLA Signed

The committers listed above are authorized under a signed CLA.

@florianl
Copy link
Contributor

Should be related to #823 not #283.

@manojVivek
Copy link
Contributor Author

Should be related to #823 not #283.

My bad, fixed it.

Co-authored-by: Florian Lehner <florianl@users.noreply.github.com>
@manojVivek manojVivek requested a review from florianl December 11, 2025 05:44
@florianl
Copy link
Contributor

florianl commented Dec 11, 2025

Can you please also update coredumps to include the column information?

Maybe something like this:

columnInfo := ""
if frame.SourceColumn != 0 {
    columnInfo = fmt.Sprintf(":%d", frame.SourceColumn)
}
fmt.Sprintf("%s+%d in %s:%d%s",
			frame.FunctionName, frame.FunctionOffset,
			frame.SourceFile, frame.SourceLine, columnInfo)

@manojVivek
Copy link
Contributor Author

Can you please also update coredumps to include the column information?

This is done.

@florianl
Copy link
Contributor

@manojVivek coredump tests are failing now (as expected), as the column information is now also provided, but not present in files like https://github.com/open-telemetry/opentelemetry-ebpf-profiler/blob/main/tools/coredump/testdata/amd64/node211.json.

@manojVivek
Copy link
Contributor Author

@manojVivek coredump tests are failing now (as expected), as the column information is now also provided, but not present in files like https://github.com/open-telemetry/opentelemetry-ebpf-profiler/blob/main/tools/coredump/testdata/amd64/node211.json.

(yeah, sorry for the ping before resolving that fully)

I believe it should be passing now, it works on the arm Mac. Also updated the files similarly for the amd64, but didn't get a chance to test it locally so waiting for the CI run.

Copy link
Contributor

@fabled fabled left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. One nit. And question for all if the line/column data type could or should be changed to 32 bit size?


// SourceColumn represents a column number within a source file line. It is intended to be used
// for the source column numbers in interpreted code.
type SourceColumn uint64
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if this should be made uint32 and the above SourceLineno also to reduce memory use?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines 15 to +16
lineNumber int64
columnNumber int64
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And here also, line/column probably could be int32?

if index > 0 {
lineStart = lineEnds[index-1] + 1
} else {
lineStart = 0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This else branch is unneeded. line start is initialized to zero.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, fixed this.

@fabled fabled merged commit 25d0fff into open-telemetry:main Jan 5, 2026
41 of 51 checks passed
@manojVivek manojVivek deleted the column-info-with-profile-frames branch January 5, 2026 09:11
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.

Support column for v8 frames

3 participants