Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

runtime: improve the "best effort" of the execution tracer's CPU sample delivery #52674

rhysh opened this issue May 3, 2022 · 0 comments


Copy link

@rhysh rhysh commented May 3, 2022

The work in (proposed for the Go 1.19 cycle) to add CPU profile samples to the execution tracer's output relies on the process generating at least a modest stream of other traceable events. If the process's goroutines as a group use more than 19 thread-seconds of CPU time before any individual P flushes a traceBuf (or before tracing ends), the profiling buffer will overflow and (silently) drop records before the goroutine calling runtime.ReadTrace wakes up to drain it.

There may be a better way to move profile samples from the profBuf into traceBufs (such as launching a goroutine to drain the profBuf).

@dr2chase dr2chase added the NeedsInvestigation label May 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet

No branches or pull requests

2 participants