Re:Sieve is simpler than LRU
by 1a1a11a on Wednesday January 03, 2024 @01:54PM
(#38858082)
> How it should work is that new items should be added at a fixed distance from the Hand pointer.
This would help with the implementation with a circular buffer. But for now, let's decouple the algorithm from the implementation.
> we can make Insert and Hand be the same slot
This is just CLOCK algorithm. It is easy to implement with a circular buffer. But the change we made deliberately improves the miss ratio significantly.
Re:Sieve is simpler than LRU
by Lanedo on Wednesday January 03, 2024 @05:57PM
(#38860971)
Wouldn't a hand that follows the head at an offset of ca 10% of the ring buffer size be mimicking the S3-FIFO quick demotion threshold and likely reap the same kind of benefits?
This would help with the implementation with a circular buffer. But for now, let's decouple the algorithm from the implementation.
> we can make Insert and Hand be the same slot
This is just CLOCK algorithm. It is easy to implement with a circular buffer. But the change we made deliberately improves the miss ratio significantly.