-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Add support for USDT probes #41685
Add support for USDT probes #41685
Conversation
@jpsamaroo might be a cool example for BPFnative.jl? |
Exciting! Thanks Valentin! :) |
Yeah agreed, thanks for picking this up again, Valentin!! |
f8a7c55
to
0ea50d7
Compare
These are working on Linux (musl) with bpftrace and BPFnative! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks terrific! Thanks Valentin! :)
Any chance we could also get probes on task switching? This could be a good, temporary alternative to #39994, where hook execution can be disabled via Preferences or some other mechanism per-package. |
For Julia code side probes there is https://github.com/JuliaPerf/UProbes.jl, but that is hamstrung by the lack of JIT support in tools bpftrace/bpftrace#425 |
I think adding probes on task switching shouldn't be too hard. One thing I haven't tested in a while is
Uhm... I don't quite understand what you are thinking about, but let's not go down the path of using eBPF programs to modify user-space on task-switches. |
I'm thinking of using it to collect metrics about executing tasks, like being able to calculate the actual CPU execution time of a task (since |
Wanna give it a go to try adding probes for that? |
By the way, building from master with
I guess |
Based on a previous exploration with @NHDaly in #31616, this PR adds a infrastructure support for USDT,
supporting
dtrace
on MacOS andbpftrace
and related tools on Linux. Support is gate by a new Make flag.As an example I added some GC probes that allow one to measure GC latencies, as an example in #41616 I was interested
in the latency distribution of stop-the-world, e.g. how long it takes until GC starts with productive work.
I hope this can provide visibilty into issues like #41586 and #33097
Inspired by https://docs.python.org/3/howto/instrumentation.html