优化MMAP相关功能

This commit is contained in:
GoEdgeLab
2024-04-04 08:28:14 +08:00
parent 4c30c28b4c
commit dcd8a0e020
12 changed files with 65 additions and 61 deletions

View File

@@ -317,7 +317,7 @@ func BenchmarkMemoryList(b *testing.B) {
b.RunParallel(func(pb *testing.PB) {
for pb.Next() {
_, _ = list.Exist(types.String("a" + types.String(rands.Int(1, 10000))))
_, _, _ = list.Exist(types.String("a" + types.String(rands.Int(1, 10000))))
_ = list.Add("a"+types.String(rands.Int(1, 100000)), &caches.Item{})
_, _ = list.Purge(1000, func(hash string) error {
return nil