Add integrated reference counting
Summary:
Add support for reference counting integrated with the internal structures and operations of the hazard pointer library. The operations are wait-free.
The advantages of this approach over combining reference counting with hazard pointers externally are:
(1) A long list of linked objects that protected by one reference can all be reclaimed together instead of going through a potentially long series of alternating reclamation and calls to retire() for descendants.
(2) Support for iterative deletion as opposed to potential deep recursion of alternating calls to release reference count and object destructors.
Reviewed By: djwatson
Differential Revision:
D6142066
fbshipit-source-id:
02bdfcbd5a2c2d5486d937bb2f9cfb6f192f5e1a