3 ms·
> reference counting will always use more ram because a reference count must be stored with every object in the system In the tracing GCs I have seen, an "obje
by cesarb 6y ago
> reference counting will always use more ram because a reference count must be stored with every object in the system
In the tracing GCs I have seen, an "object header" must be stored with every object in the system; the GC needs it to know which parts of the object are references which should be traced. So while reference counting needs extra space to store the reference count, tracing GC needs extra space to store the object header.