Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Ruby Garbage Collection
Search
Simon Hørup Eskildsen
May 06, 2013
Programming
1
180
Ruby Garbage Collection
Simon Hørup Eskildsen
May 06, 2013
Tweet
Share
More Decks by Simon Hørup Eskildsen
See All by Simon Hørup Eskildsen
Advanced Napkin Math: Estimating System's Performance from First Principles
sirupsen
3
710
GOTO Copenhagen 2017: Shopify’s Architecture to Handle 80K RPS Sales
sirupsen
0
620
RailsConf 2016: 5 Years of Scaling Rails to 80K RPS
sirupsen
3
1.1k
Full Stack Fest 2016: Shopify in Multiple Datacenters
sirupsen
6
470
CUSEC 2016: Reliable Software in a Chaotic World
sirupsen
5
660
EuRuKo 2015: Super-Reliable Software
sirupsen
12
3.5k
DockerCon 2015: Resilient Routing and Discovery
sirupsen
22
6.6k
Goruco 2015: Building and Testing Resilient Applications
sirupsen
2
340
GOTO Chicago: Patterns for Docker Success
sirupsen
1
330
Other Decks in Programming
See All in Programming
DevinとClaude Code、SREの現場で使い倒してみた件
karia
1
730
Ruby x Terminal
a_matsuda
5
500
Amazon Bedrockを活用したRAGの品質管理パイプライン構築
tosuri13
5
900
Railsの気持ちを考えながらコントローラとビューを整頓する/tidying-rails-controllers-and-views-as-rails-think
moro
4
350
LangChain4jとは一味違うLangChain4j-CDI
kazumura
1
120
2026年は Rust 置き換えが流行る! / 20260220-niigata-5min-tech
girigiribauer
0
210
メタプログラミングで実現する「コードを仕様にする」仕組み/nikkei-tech-talk43
nikkei_engineer_recruiting
0
130
今、アーキテクトとして 品質保証にどう関わるか
nealle
0
190
Oxlint JS plugins
kazupon
1
1.1k
AI時代のキャリアプラン「技術の引力」からの脱出と「問い」へのいざない / tech-gravity
minodriven
22
8.1k
Rubyと楽しいをつくる / Creating joy with Ruby
chobishiba
0
200
オブザーバビリティ駆動開発って実際どうなの?
yohfee
2
620
Featured
See All Featured
Amusing Abliteration
ianozsvald
0
120
HDC tutorial
michielstock
1
470
Beyond borders and beyond the search box: How to win the global "messy middle" with AI-driven SEO
davidcarrasco
2
65
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
37
6.3k
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
470
Digital Projects Gone Horribly Wrong (And the UX Pros Who Still Save the Day) - Dean Schuster
uxyall
0
550
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.2k
4 Signs Your Business is Dying
shpigford
187
22k
YesSQL, Process and Tooling at Scale
rocio
174
15k
The AI Search Optimization Roadmap by Aleyda Solis
aleyda
1
5.3k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
69
Crafting Experiences
bethany
1
73
Transcript
Ruby Garbage Collection Simon Hørup Eskildsen @Sirupsen
None
Mark and Sweep (< 1.9) Lazy Sweeping (>= 1.9) Lazy
Bitmask Sweeping (2.0) Geneartional GC (2.1?) Concurrent GC (??)
Mark and Sweep
None
None
RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE
None
None
Root objects Freeable
None
RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE
RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE
None
RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE
Free List
RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE
Free List
RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE Free
List
RVALUE RCLASS RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE RVALUE Free
List
The Copy-on-Write Problem
None
None
Process #2 Process #1
Process #2 Process #1
None
None
Process #2 Process #1 ? ? ? ? ? ?
?
None
Process #2 Process #1
Ruby 2.0
0 0 1 0 0 1 1
None
Process #2 Process #1 bar foo
CoW problem fixed: => Less memory => Faster
Geneartional GC Ruby 2.1?
Root objects Freeable M&S Freeable
Old Root objects Freeable Old M&S Freeable
Prospects of a Concurrent GC