-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: fix w-TinyLFU frequencies updates #850
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: MrCroxx <mrcroxx@outlook.com>
bench_hit_ratiobaseline (main)
PR
|
This PR shows higher hit ratio when zipf_exp is under 1.0 . Let's check the behavior with mokabench. |
Hi. Oops. I meant the following:
I thought |
My bad. I may not have been fully awake when writing the PR. 🥹 |
Signed-off-by: MrCroxx <mrcroxx@outlook.com>
Hi. I ran some mokabench benchmarks comparing the hit ratio of different $ cargo run -F foyer --release -- --num-clients 1
As for the change to make Foyer not to update the frequency when inserting, the above tests are not very good to show the difference. It would be better to do a test where you insert the same key multiple times without reading it. It will skew the hit ratio if the frequency is updated on inserts. I found that making the number of shards smaller (1) makes the hit ratio better when the max capacity is around 400k. I think having all keys in the same shard makes the eviction policy more effective. I could not find the reason for the difference in hit ratio between the |
Thank you for helping, @tatsuya6502 . 🥰 I'm also investigating the cache hit/miss trace for more information. However, it might be a little slow these days because of some family activities during CNY. |
What's changed and what's your intention?
As @tatsuya6502 suggested in #849 , this PR:
Thank @tatsuya6502 for help. 🥰
Checklist
make all
(ormake fast
instead if the old tests are not modified) in my local environment.Related issues or PRs (optional)
close #849