How does a copying garbage collector ensure objects are not accessed while copied?

前端 未结 3 2383
死守一世寂寞
死守一世寂寞 2021-02-20 04:44

On collection, the garbage collector copies all live objects into another memory space, thus discarding all garbage objects in the process. A forward pointer to the copied objec

3条回答
  •  不思量自难忘°
    2021-02-20 05:11

    The Loaded Value Barrier implemented in Azul's Generational Pauseless Garbage Collector is an example of a solution to this problem. You can read about it in the article The Azul Garbage Collector posted on InfoQ in early 2011.

提交回复
热议问题