scalalang2 / golang-fifo

Modern efficient cache design with simple FIFO queue only in Golang
MIT License
142 stars 7 forks source link

[ENHANCEMENT] Enhance performance #12

Closed scalalang2 closed 10 months ago

scalalang2 commented 11 months ago

Motivation

Let's explore a way to enhance the performance of this implementation 🤔

scalalang2 commented 11 months ago

To minimize GC overhead, we can use this technique used at vitess, which is a sharded database compatible with MySQL

sylr commented 11 months ago

See https://github.com/golang/go/issues/62483

scalalang2 commented 11 months ago

@sylr thanks for sharing it 👍 I'll follow this up.

scalalang2 commented 11 months ago

See also go-ethereum/common/lru/blob_lru.go