Garbage Collection Performance

The cluster focuses on debates about garbage collection (GC) latency, pauses, and efficiency in languages like Go and Java, comparing GC to manual memory management and its suitability for real-time and performance-critical applications.

📉 Falling 0.4x Programming Languages
6,804
Comments
20
Years Active
5
Top Authors
#3060
Topic ID

Activity Over Time

2007
1
2008
11
2009
52
2010
83
2011
182
2012
208
2013
317
2014
355
2015
485
2016
650
2017
461
2018
390
2019
569
2020
602
2021
605
2022
602
2023
416
2024
393
2025
419
2026
3

Keywords

RAM MarkAndSweep C4 GC OP BLAS special.html ZGC CLR LAPACK gc memory latency garbage collection low latency collection garbage memory management tracing heap

Sample Comments

adgjlsfhk1 May 4, 2023 View on HN

Garbage collection isn't slow. good GC systems have similar overhead to malloc/free.

GFK_of_xmaspast Sep 19, 2015 View on HN

Doesn't go's GC work as well as it does because it's a 'stop the world' single-threaded implementation?

jerf Nov 30, 2015 View on HN

Much more than "a realistic chance of optimizing everything else to the point that GC time becomes your biggest problem"?

naasking Oct 3, 2017 View on HN

Real-time GCs with microsecond latencies do exist.

weberc2 Sep 21, 2019 View on HN

You didn't have a bad experience with GC in the past, you had a bad experience with a single GC implementation, one which was almost certainly optimized for throughput and not latency and in a language that pushes you toward GC pressure by default. :)

Capricorn2481 Aug 22, 2025 View on HN

Do you have a source for this? My understanding is Go's GC is much better optimized for low latency.

viraptor Jul 14, 2021 View on HN

Why wouldn't it be? There's no forced GC, you can have custom application in arenas, etc. Pretty much all tricks used for low latency are available.

apta Mar 10, 2019 View on HN

There are Java GCs that are optimized for latency. Check out project Shenandoah and ZGC for examples.

axod Feb 25, 2011 View on HN

GC isn't a problem for realtime systems, if configured correctly. For example, have the GC running incrementally in a separate thread.

platz Apr 21, 2017 View on HN

OP probably wants a Concurrent/MarkAndSweep GC rather than a Generational GC. because 16 ms is too much for game dev