#signal #profiler #profiling #signal-handler #running #programs #ckb-vm

ckb-vm-signal-profiler

Linux signal based profiler for ckb-vm, note this is profiling ckb-vm itself, not the programs running in ckb-vm

10 releases (breaking)

0.119.0 Oct 25, 2024
0.118.0-rc1 Aug 28, 2024
0.117.0 Jul 30, 2024
0.115.0-rc2 Mar 21, 2024
0.112.1 Nov 22, 2023

#16 in #signal-handler

Download history 94/week @ 2024-08-25 95/week @ 2024-09-01 6/week @ 2024-09-08 134/week @ 2024-09-15 13/week @ 2024-09-22 4/week @ 2024-09-29 1/week @ 2024-10-06 12/week @ 2024-10-13 106/week @ 2024-10-20 15/week @ 2024-10-27 26/week @ 2024-11-03 1/week @ 2024-11-10

756 downloads per month

MIT license

22KB
423 lines

ckb-vm-signal-profiler

Signal based profiler for ckb-vm. Like gperftools, it uses a SIGPROF signal handler to suspend running CKB-VM programs so as to gather profiling data. One advantage of this solution, is that it requires no code injections into CKB-VM. However also due to this design choice, this profiler runs on Linux only for the moment.

See here for an example on using this library.

This library inherits a lot of the signal handler related code from pprof-rs library.

Notes

  • If anything weird happens when loading the generated profiling data, make sure you are using the golang based pprof at here, not the binary from gperftools with the same name.

Dependencies

~11MB
~215K SLoC