Finding Memory Leaks in the Ruby Ecosystem
summary
Experimental Ruby free at exit adds an environment toggle in Ruby 3.3 to free allocations at shutdown so native-memory tools can report real leaks; it cuts Valgrind output from ~100,000 noisy lines to about 32 relevant ones, lets Valgrind and macOS leaks detect native issues, and finds over 20 real leaks in Ruby (one regex-timeout leak grew ~3 GB before the fix and flattens after). The existing Ruby MemCheck adapts to use the feature for gem testing.
AI-written summary · about
chapters (7)
- 0:00Introduction
- 1:32What is a memory leak
- 5:22Prior art and Ruby MemCheck
- 9:55Ruby free at exit feature
- 14:10Finding leaks with the feature
- 20:45Using the feature in practice
- 21:27Q&A and closing
related talks
39mPointers for Eliminating Heaps of Memory
29mWhat causes Ruby memory bloat?
45mClosing Keynote: Analyzing and Reducing Ruby Memory Usage
42mDebugging Ruby
27mParallel Ruby: Managing the Memory Monster
38mWhy I am excited about Ruby 2.1?
24mRuby Performance Secrets and How to Uncover Them
34mHow to optimize Ruby internal.
