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
190
1
Share
Ruby Garbage Collection
Simon Hørup Eskildsen
May 06, 2013
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
630
RailsConf 2016: 5 Years of Scaling Rails to 80K RPS
sirupsen
3
1.1k
Full Stack Fest 2016: Shopify in Multiple Datacenters
sirupsen
6
480
CUSEC 2016: Reliable Software in a Chaotic World
sirupsen
5
660
EuRuKo 2015: Super-Reliable Software
sirupsen
12
3.6k
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
感情を設計する
ichimichi
3
450
forteeの改修から振り返るPHPerKaigi 2026
muno92
PRO
3
210
「速くなった気がする」をデータで疑う
senleaf24
0
130
生成 AI 時代のスナップショットテストってやつを見せてあげますよ(α版)
ojun9
0
340
GoのDB アクセスにおける 「型安全」と「柔軟性」の両立 - Bob という選択肢
tak848
0
300
KagglerがMixSeekを触ってみた
morim
0
370
「接続」—パフォーマンスチューニングの最後の一手 〜点と点を結ぶ、その一瞬のために〜
kentaroutakeda
5
2.4k
AIコードレビューの導入・運用と AI駆動開発における「AI4QA」の取り組みについて
hagevvashi
0
600
Linux Kernelの1文字のミスで 権限昇格ができた話
rqda
0
2.3k
見せてもらおうか、 OpenSearchの性能とやらを!
shunta27
1
170
Codex CLIのSubagentsによる並列API実装 / Parallel API Implementation with Codex CLI Subagents
takatty
2
820
レガシーPHP転生 〜父がドメインエキスパートだったのでDDD+Claude Codeでチート開発します〜
panda_program
0
190
Featured
See All Featured
Code Review Best Practice
trishagee
74
20k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
31
10k
brightonSEO & MeasureFest 2025 - Christian Goodrich - Winning strategies for Black Friday CRO & PPC
cargoodrich
3
140
How to optimise 3,500 product descriptions for ecommerce in one day using ChatGPT
katarinadahlin
PRO
1
3.5k
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
700
Context Engineering - Making Every Token Count
addyosmani
9
790
Primal Persuasion: How to Engage the Brain for Learning That Lasts
tmiket
0
310
Practical Orchestrator
shlominoach
191
11k
RailsConf 2023
tenderlove
30
1.4k
What's in a price? How to price your products and services
michaelherold
247
13k
B2B Lead Gen: Tactics, Traps & Triumph
marketingsoph
0
96
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
300
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