~/talk

Closing Keynote: Analyzing and Reducing Ruby Memory Usage

Talkat GORUCO 2018 · on Saturday, 2018-06-16· [ruby]

Two C-level patches target real Rails boot pain: a loaded features cache change that uses shared C strings and avoids Ruby string allocations (saves about 4.2% of boot memory on a sample Rails boot), and direct instruction sequence marking that removes the persistent mark array so GC marks bytecode operands directly (cuts object count ~34% and overall process memory ~6%). Findings come from malloc stack logging / malloc_history on macOS plus AllocationTracer/ObjectSpace instrumentation, and land in Ruby 2.6.

AI-written summary · about

  1. 0:00Start
  2. 0:05CLOSING KEYNOTE: ANALYZING AND REDUCING RUBY MEMORY USAGE
  3. 10:39Malloc Stack Logging
  4. 11:33Dump Malloc Logs
  5. 12:07File Contents
  6. 12:38Reconciling Live Memory
  7. 13:50Top 20 Allocators
  8. 17:30Requiring The Same File
  9. 18:25Cache Generation
  10. 18:45Cache Structure
  11. 19:08Generation Algorithm
  12. 19:22Key Generation
  13. 22:37Output
  14. 23:04Malloc Logging
  15. 26:00Stack VM
  16. 27:02Processing Phases
  17. 29:34Optimization Pass
  18. 30:29Byte Code Translation
  19. 32:34Hello World
  20. 34:11VM Implementation
  21. 35:22Execute 3 Times
  22. 36:02Object Allocations
  23. 37:22ISeq Layout
  24. 41:52Mark Loop
  25. 42:25Basic Rails App
  26. 43:25Process Memory: -6%
  27. 44:17Actual Code
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 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
?
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.