branchrust_reboot/main/pool_leak_experiments/lprqcancel
10 Commits over 0 Days - Infinitycph!
Update(tests): expand TestAllocWhenEmpty test slightly to sanity check leaking behavior
Tests: ran unit test
Clean: Add general explanation on the pool implementation
- remove TODOs
- buildfix for non-editor builds
- bugfix of setting the wrong epoch for a slot for stale cells
Tests: ran unit and perf tests
Optim: inline LPRQ segment logic, get rid of the overall queue
Perf test is averaging 2.8ms, improvement over FuzzyPool by 20%
Tests: unit tests + AllocDeallocMTShortLived(32,False) perf test
Optim: use same trick of oversized segment to avoid segment churn
Looks faster than FuzzyPool, noice
Tests: ran unit tests + select perf tests
Update: minor simplifications
- get rid of retry limiters
- fixup unsafe increments
Couldn't figure out how to do add segment recycling, so going to change focus for a bit - will see how ConcurrentQueue performs
Tests: ran unit tests
Optim: reduce GC impact by reducing how many segments we trash
This forces serialization at the point of segment exhaustion. Need to see if I can setup some sort of recycling to reduce busy spinning
Tests: ran AllocDeallocMTShortLived(32, false), no more GC reports
Bugfix(tests): fix 2 pooling tests having bad setup after Spillage tests
These tests rely on explicit sizes/counters, so were randomly failing
Tests: ran all PoolTests unit tests
Update: add a bunch of perf counters to try to track down the spike source
- slightly amend Enqueue to help progress swap before creating a new segment if it failed
The spikes are from GC collection events, likely triggered by excessive trashing of segments(after 10 runs - 106 created, 97 trashed)
Tests: ran AllocDeallocMTShortLived(32, false) perf test
Update: reimplement pool internals on top of LPRQ
Based on paper by Raed Romanov & Nikita Koval: https://dl.acm.org/doi/epdf/10.1145/3572848.3577485
Shows same or a bit better times than FuzzyPool, but periodically has a very spiky test (from 2ms to 40ms). Also needs further tweaking and documenting
Tests: ran unit & perf tests