~/talk

The depths of profiling Ruby

Talkat RubyKaigi 2024 · 2024-05-15..05-17· [ruby]
links:none on file
slides:none on file

Announces a new profiler called pf2 profiler that samples Ruby and C stacks, records per-kernel-thread CPU time via timer_create/SIGPROF, and matches libtrace-collected PC values to Ruby threads; uses rb_profile_thread_frames, TracePoint and thread events for GC/GVL state, unwinds C stacks with libbacktrace/DWARF after the run, and visualizes with the Firefox profiler. Implementation is in Rust, aims for <5% overhead with a 19 ms default sampling rate, and adds FE-extension visibility (example: MyQ2) so hidden C-level hotspots become visible.

AI-written summary · about

  1. 0:00Introduction and motivation
  2. 1:37What is a profiler
  3. 3:00Introducing pf2 profiler
  4. 8:25Profiler mission and design
  5. 10:55Collecting Ruby stack samples
  6. 14:54Profiling C extensions
  7. 15:37Sampling scheduling strategies
  8. 18:28Controlling overhead
  9. 20:36Unwinding and aggregation
  10. 23:47Visualization and tools
  11. 24:53Future of Ruby profiling
  12. 26:41Acknowledgements and Q&A
~/search
type to search 8,222 conferences, 162,397 speakers and 219,688 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
← →
on a talk: 5 seconds back / forward
0–9
on a talk: jump to 0%–90% of the recording
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.