You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add lock-free BlockPageResource for ImmixSpace (#506)
This PR adds a lock-free block queue and uses it for Immix's clean block allocation (as `BlockPageResource`) and recyclable block allocation (as a reusable block queue).
The lock-free block queue has per-thread producer endpoints. Only GC workers can add blocks to the queue. Workers will add the blocks to their thread-local queues first, and flush them to the global pool if the queue is full.
Block allocation can only happen at block granularity. The consumers still share a single endpoint. But on block allocation fast-path, the cost is just a simple atomic increment to update the allocation cursor and pop a block. _However, for `BlockPageResource`, considering the current design of `Space.acquire`, it still acquires a lock before calling `pr.get_new_pages`._
0 commit comments