$30 off During Our Annual Pro Sale. View Details »
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
700
GOTO Copenhagen 2017: Shopify’s Architecture to Handle 80K RPS Sales
sirupsen
0
610
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
650
EuRuKo 2015: Super-Reliable Software
sirupsen
12
3.3k
DockerCon 2015: Resilient Routing and Discovery
sirupsen
22
6.6k
Goruco 2015: Building and Testing Resilient Applications
sirupsen
2
330
GOTO Chicago: Patterns for Docker Success
sirupsen
1
320
Other Decks in Programming
See All in Programming
AIコーディングエージェント(Manus)
kondai24
0
150
AIコーディングエージェント(skywork)
kondai24
0
130
LLM Çağında Backend Olmak: 10 Milyon Prompt'u Milisaniyede Sorgulamak
selcukusta
0
100
複数人でのCLI/Infrastructure as Codeの暮らしを良くする
shmokmt
5
2.2k
AIコードレビューがチームの"文脈"を 読めるようになるまで
marutaku
0
340
251126 TestState APIってなんだっけ?Step Functionsテストどう変わる?
east_takumi
0
300
20 years of Symfony, what's next?
fabpot
2
330
AIコーディングエージェント(NotebookLM)
kondai24
0
150
Microservices rules: What good looks like
cer
PRO
0
870
愛される翻訳の秘訣
kishikawakatsumi
1
270
配送計画の均等化機能を提供する取り組みについて(⽩⾦鉱業 Meetup Vol.21@六本⽊(数理最適化編))
izu_nori
0
140
AIエージェントを活かすPM術 AI駆動開発の現場から
gyuta
0
300
Featured
See All Featured
GraphQLの誤解/rethinking-graphql
sonatard
73
11k
Speed Design
sergeychernyshev
33
1.4k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
8.3k
Git: the NoSQL Database
bkeepers
PRO
432
66k
How to Ace a Technical Interview
jacobian
280
24k
Building Adaptive Systems
keathley
44
2.9k
Facilitating Awesome Meetings
lara
57
6.7k
Why Our Code Smells
bkeepers
PRO
340
57k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
120
20k
Navigating Team Friction
lara
191
16k
Thoughts on Productivity
jonyablonski
73
5k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
34
2.5k
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