buzz icon indicating copy to clipboard operation
buzz copied to clipboard

Experiment with semi-space GC

Open giann opened this issue 3 months ago • 0 comments

https://en.wikipedia.org/wiki/Cheney%27s_algorithm

Used in some form by Java, .NET, V8, SpiderMonkey.

They use it for the young generation to avoid using to much memory. Since the young are the most common objects and its the space that moves the most, it makes sense.

Java has 3 spaces:

  • Eden: surviving objects move to S0, dead ones are discarded
  • S0 and S1 which are semi-space that swap
  • Old generation (mark and sweep)

Young generation could be a semi-space that is never freed and rarely shrinked.

giann avatar Sep 18 '25 07:09 giann