Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Atomic reference counting per se is fairly slow compared to other simple operations [1]. But the biggest issue with reference counting is that it doesn't scale well in multithreaded programs: even pure readers have to write to shared memory locations. Also acquiring a new reference from a shared atomic pointer is complex and need something like hazard pointers or a lock.

[1] an atomic inc on x86 is typically ~30 clock cycles, doesn't really pipeline well and will stall at the very least other load operations.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: