NixOS / nix

Nix, the purely functional package manager
https://nixos.org/
GNU Lesser General Public License v2.1
12.06k stars 1.47k forks source link

Support for userspace tracepoints #5193

Open Mic92 opened 3 years ago

Mic92 commented 3 years ago

Is your feature request related to a problem? Please describe.

Right now our flamegraphs has a significant performance impact and also only show nix code samples.

Describe the solution you'd like

On systems with eBPF or dtrace we can leverage userspace tracepoints. This allows to profile both C++/Nix stack samples at the same time with little overhead. In particular nix would provide an API for the kernel to expose the current nix function stack that is executed. Python, PHP and java provide similar probes. Also read this article for more information: https://lwn.net/Articles/753601/

Describe alternatives you've considered

Right now we can only profile nix code with high overhead or we can profile the c++ code base while missing out on the information what nix code is currently running.

stale[bot] commented 2 years ago

I marked this as stale due to inactivity. → More info