@@ -6077,6 +6077,8 @@ namespace facebook::cachelib {
60776077extern template class CacheAllocator <LruCacheTrait>;
60786078extern template class CacheAllocator <LruCacheWithSpinBucketsTrait>;
60796079extern template class CacheAllocator <Lru2QCacheTrait>;
6080+ extern template class CacheAllocator <S3FIFOCacheTrait>;
6081+ extern template class CacheAllocator <S3FIFO5BCacheTrait>;
60806082extern template class CacheAllocator <TinyLFUCacheTrait>;
60816083extern template class CacheAllocator <WTinyLFUCacheTrait>;
60826084
@@ -6098,6 +6100,15 @@ using LruAllocatorSpinBuckets = CacheAllocator<LruCacheWithSpinBucketsTrait>;
60986100using Lru2QAllocator = CacheAllocator<Lru2QCacheTrait>;
60996101using Lru5B2QAllocator = CacheAllocator<Lru5B2QCacheTrait>;
61006102
6103+ // CacheAllocator with S3 FIFO eviction policy
6104+ // It maintains 2 queues, one for for probation and one for the main queue.
6105+ // New items are added to the probation queue, and if not accessed
6106+ // will be quickly removed from the cache to remove 1 hit wonders.
6107+ // If accessed while in probation, it will eventually be promoted to the main queue.
6108+ // Items in the tail of main queue will be reinserted if accessed.
6109+ using S3FIFOAllocator = CacheAllocator<S3FIFOCacheTrait>;
6110+ using S3FIFO5BAllocator = CacheAllocator<S3FIFO5BCacheTrait>;
6111+
61016112// CacheAllocator with Tiny LFU eviction policy
61026113// It has a window initially to gauage the frequency of accesses of newly
61036114// inserted items. And eventually it will onl admit items that are accessed
0 commit comments