3 ms·
>C++ on Windows makes heavy use of reference counting (which is a GC algorithm from CS point of view), via COM/UWP. Not sure if Ref counting is a good example
by therockhead 7y ago
>C++ on Windows makes heavy use of reference counting (which is a GC algorithm from CS point of view), via COM/UWP.
Not sure if Ref counting is a good example here, as there is no runtime monitoring the object graph hierarchy and of course Rust it’s self uses ref counting in many situations.
- pjmlp 7y agoChapter 5 of "The Garbage Collection Handbook", one of the GC gospel books. Reference Counting is a garbage collection implementation algorithm from CS point of view. RC has plenty of runtime costs as well, cache invalidation, lock contention on reference counters, stop the world in complex data structures, possible stack overflows if destructors are incorrectly written, memory fragmentation.