cache
cache copied to clipboard
Add xsync.Map as cache backend
Lines Of Code
| Language | Files | Lines | Code | Comments | Blanks | Complexity | Bytes |
|---|---|---|---|---|---|---|---|
| Go | 15 (+1) | 2290 (+304) | 1597 (+214) | 209 (+20) | 484 (+70) | 306 (+33) | 48K (+5.9K) |
| Go (test) | 15 (+1) | 2460 (+176) | 1839 (+140) | 117 (+6) | 504 (+30) | 153 (+9) | 55.8K (+4K) |
API Changes
# github.com/bool64/cache ## compatible changes (*shardedMap).Load: added (*shardedMap).Store: added NewXsyncMap: added XsyncMap: added # summary Inferred base version: v0.2.1 Suggested version: v0.3.0
Unit Test Coverage
total: (statements) 80.3%
Coverage diff with base branch
79c79,93
< total: (statements) 79.8%
---
> github.com/bool64/cache/xsync_map.go NewXsyncMap 100.0%
> github.com/bool64/cache/xsync_map.go Read 75.0%
> github.com/bool64/cache/xsync_map.go Write 100.0%
> github.com/bool64/cache/xsync_map.go Delete 100.0%
> github.com/bool64/cache/xsync_map.go ExpireAll 100.0%
> github.com/bool64/cache/xsync_map.go DeleteAll 62.5%
> github.com/bool64/cache/xsync_map.go deleteExpiredBefore 0.0%
> github.com/bool64/cache/xsync_map.go Len 100.0%
> github.com/bool64/cache/xsync_map.go Walk 80.0%
> github.com/bool64/cache/xsync_map.go Dump 100.0%
> github.com/bool64/cache/xsync_map.go Restore 90.9%
> github.com/bool64/cache/xsync_map.go evictOldest 94.1%
> github.com/bool64/cache/xsync_map.go heapInUseOverflow 100.0%
> github.com/bool64/cache/xsync_map.go countOverflow 0.0%
> total: (statements) 80.3%
Benchmark Result
Benchmark diff with base branch
name old time/op new time/op delta
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 208ns ± 7% 208ns ± 4% ~ (p=0.841 n=5+5)
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 126ns ± 2% 126ns ± 3% ~ (p=0.794 n=5+5)
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 114ns ± 4% 114ns ± 3% ~ (p=1.000 n=5+5)
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 122ns ± 2% 126ns ± 1% +3.17% (p=0.016 n=5+5)
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 108ns ± 3% 110ns ± 2% ~ (p=0.095 n=5+5)
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 63.3ns ± 2% 63.6ns ± 0% ~ (p=0.730 n=5+4)
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 85.3ns ± 1% 84.9ns ± 3% ~ (p=0.222 n=5+5)
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 128ns ± 2% 131ns ± 1% +2.60% (p=0.016 n=5+5)
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 154ns ± 2% 158ns ± 2% ~ (p=0.056 n=5+5)
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 311ns ± 1% 321ns ± 1% +2.97% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 453ns ± 3% 482ns ± 2% +6.30% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 616ns ±25% 671ns ±26% ~ (p=0.421 n=5+5)
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 279ns ± 1% 298ns ± 6% +6.68% (p=0.016 n=4+5)
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 541ns ±108% 548ns ±111% ~ (p=0.841 n=5+5)
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 323ns ±33% 347ns ±21% ~ (p=0.690 n=5+5)
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 230ns ± 8% 234ns ± 5% ~ (p=0.548 n=5+5)
_ShardedByteMap_concurrent-2 125ns ± 0% 130ns ± 4% +4.20% (p=0.016 n=4+5)
_Failover_noSyncRead-2 134ns ± 2% 141ns ± 7% ~ (p=0.095 n=5+5)
_FailoverSyncRead-2 434ns ± 2% 432ns ± 2% ~ (p=0.690 n=5+5)
_FailoverAlwaysBuild-2 1.71µs ± 1% 1.65µs ± 1% -3.05% (p=0.008 n=5+5)
ShardedMap_Dump-2 3.86µs ± 2% 3.84µs ± 2% ~ (p=0.548 n=5+5)
name old MB/inuse new MB/inuse delta
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 2.27 ± 0% 2.20 ± 0% -2.78% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 2.21 ± 0% 2.19 ± 0% -1.04% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 2.76 ± 0% 2.80 ± 0% +1.41% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 1.91 ± 0% 1.91 ± 0% ~ (all equal)
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 2.62 ± 0% 2.60 ± 0% -0.88% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 1.91 ± 0% 1.88 ± 0% -2.04% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 1.91 ± 0% 1.91 ± 0% -0.42% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 2.18 ± 0% 2.18 ± 0% ~ (all equal)
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 2.19 ± 0% 2.18 ± 0% -0.68% (p=0.008 n=5+5)
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 2.19 ± 0% 2.18 ± 0% -0.37% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 208 ± 0% 210 ± 0% +1.01% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 287 ± 0% 286 ± 0% -0.17% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 200 ± 0% 200 ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 274 ± 0% 278 ± 0% +1.24% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 192 ± 0% 192 ± 0% +0.16% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 200 ± 0% 200 ± 0% +0.20% (p=0.008 n=5+5)
name old ms/preload new ms/preload delta
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 12.9 ± 0% 15.4 ± 0% +19.89% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 12.7 ± 0% 11.7 ± 0% -8.03% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 16.9 ± 0% 16.5 ± 0% -2.66% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 5.84 ± 0% 6.12 ± 0% +4.79% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 9.41 ± 0% 9.23 ± 0% -1.92% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 6.37 ± 0% 6.68 ± 0% +4.90% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 4.36 ± 0% 4.81 ± 0% +10.28% (p=0.008 n=5+5)
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 11.6 ± 0% 11.9 ± 0% +2.60% (p=0.008 n=5+5)
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 12.0 ± 0% 12.5 ± 0% +4.52% (p=0.008 n=5+5)
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 12.6 ± 0% 12.5 ± 0% -0.79% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 1.84k ± 0% 1.94k ± 0% +5.83% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 2.99k ± 0% 2.84k ± 0% -4.92% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 1.02k ± 0% 1.03k ± 0% +0.98% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 2.04k ± 0% 2.12k ± 0% +3.87% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 1.78k ± 0% 1.72k ± 0% -3.31% (p=0.008 n=5+5)
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 781 ± 0% 971 ± 0% +24.34% (p=0.008 n=5+5)
name old alloc/op new alloc/op delta
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 3.00B ± 0% 3.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 3.00B ± 0% 3.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 3.00B ± 0% 3.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 3.00B ± 0% 3.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 3.00B ± 0% 3.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 3.00B ± 0% 3.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 3.00B ± 0% 3.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 4.00B ± 0% 4.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 7.00B ± 0% 7.00B ± 0% ~ (all equal)
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 39.0B ± 0% 39.0B ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 43.0B ± 0% 43.0B ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 61.0B ±28% 61.6B ±28% ~ (p=0.683 n=5+5)
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 24.0B ± 0% 24.0B ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 46.6B ±91% 46.6B ±91% ~ (p=1.000 n=5+5)
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 23.0B ± 0% 29.2B ±37% ~ (p=0.556 n=4+5)
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 24.0B ± 0% 24.0B ± 0% ~ (all equal)
_ShardedByteMap_concurrent-2 3.00B ± 0% 3.00B ± 0% ~ (all equal)
_Failover_noSyncRead-2 0.00B 0.00B ~ (all equal)
_FailoverSyncRead-2 160B ± 0% 160B ± 0% ~ (all equal)
_FailoverAlwaysBuild-2 447B ± 0% 447B ± 0% ~ (all equal)
ShardedMap_Dump-2 861B ± 2% 846B ± 1% ~ (p=0.111 n=5+5)
name old allocs/op new allocs/op delta
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 0.00 0.00 ~ (all equal)
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 0.00 0.00 ~ (all equal)
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 0.00 0.00 ~ (all equal)
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 0.00 0.00 ~ (all equal)
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 0.00 0.00 ~ (all equal)
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 0.00 0.00 ~ (all equal)
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 0.00 0.00 ~ (all equal)
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 0.00 0.00 ~ (all equal)
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 1.00 ± 0% 1.00 ± 0% ~ (all equal)
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 1.00 ± 0% 1.00 ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 1.00 ± 0% 1.00 ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 2.00 ± 0% 2.00 ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 1.00 ± 0% 1.00 ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 1.00 ± 0% 1.00 ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 1.00 ± 0% 1.00 ± 0% ~ (all equal)
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 1.00 ± 0% 1.00 ± 0% ~ (all equal)
_ShardedByteMap_concurrent-2 0.00 0.00 ~ (all equal)
_Failover_noSyncRead-2 0.00 0.00 ~ (all equal)
_FailoverSyncRead-2 3.00 ± 0% 3.00 ± 0% ~ (all equal)
_FailoverAlwaysBuild-2 11.0 ± 0% 11.0 ± 0% ~ (all equal)
ShardedMap_Dump-2 13.0 ± 0% 13.0 ± 0% ~ (all equal)
Benchmark result
name time/op
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 208ns ± 4%
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 126ns ± 3%
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 114ns ± 3%
_concurrent/c10000:g2:w0.00%:failover(*cache.XsyncMap)-2 121ns ± 2%
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 126ns ± 1%
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 110ns ± 2%
_concurrent/c10000:g2:w0.00%:*cache.XsyncMap-2 104ns ± 2%
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 63.6ns ± 0%
_concurrent/c10000:g2:w0.00%:xsync.Map-base-2 60.1ns ± 0%
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 84.9ns ± 3%
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 131ns ± 1%
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 158ns ± 2%
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 321ns ± 1%
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 482ns ± 2%
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 671ns ±26%
_concurrent/c1000000:g2:w10.00%:failover(*cache.XsyncMap)-2 548ns ± 2%
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 298ns ± 6%
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 548ns ±111%
_concurrent/c1000000:g2:w10.00%:*cache.XsyncMap-2 327ns ± 1%
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 347ns ±21%
_concurrent/c1000000:g2:w10.00%:xsync.Map-base-2 226ns ± 1%
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 234ns ± 5%
_ShardedByteMap_concurrent-2 130ns ± 4%
_Failover_noSyncRead-2 141ns ± 7%
_FailoverSyncRead-2 432ns ± 2%
_FailoverAlwaysBuild-2 1.65µs ± 1%
ShardedMap_Dump-2 3.84µs ± 2%
name MB/inuse
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 2.20 ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 2.19 ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 2.80 ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.XsyncMap)-2 2.83 ± 0%
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 1.91 ± 0%
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 2.60 ± 0%
_concurrent/c10000:g2:w0.00%:*cache.XsyncMap-2 2.33 ± 0%
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 1.88 ± 0%
_concurrent/c10000:g2:w0.00%:xsync.Map-base-2 1.55 ± 0%
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 1.91 ± 0%
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 2.18 ± 0%
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 2.18 ± 0%
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 2.18 ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 210 ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 286 ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.XsyncMap)-2 282 ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 200 ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 278 ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.XsyncMap-2 269 ± 0%
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 192 ± 0%
_concurrent/c1000000:g2:w10.00%:xsync.Map-base-2 190 ± 0%
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 200 ± 0%
_ShardedByteMap_concurrent-2
_Failover_noSyncRead-2
_FailoverSyncRead-2
_FailoverAlwaysBuild-2
ShardedMap_Dump-2
name ms/preload
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 15.4 ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 11.7 ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 16.5 ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.XsyncMap)-2 14.1 ± 0%
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 6.12 ± 0%
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 9.23 ± 0%
_concurrent/c10000:g2:w0.00%:*cache.XsyncMap-2 6.97 ± 0%
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 6.68 ± 0%
_concurrent/c10000:g2:w0.00%:xsync.Map-base-2 4.36 ± 0%
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 4.81 ± 0%
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 11.9 ± 0%
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 12.5 ± 0%
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 12.5 ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 1.94k ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 2.84k ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.XsyncMap)-2 2.38k ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 1.03k ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 2.12k ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.XsyncMap-2 1.66k ± 0%
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 1.72k ± 0%
_concurrent/c1000000:g2:w10.00%:xsync.Map-base-2 1.31k ± 0%
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 971 ± 0%
_ShardedByteMap_concurrent-2
_Failover_noSyncRead-2
_FailoverSyncRead-2
_FailoverAlwaysBuild-2
ShardedMap_Dump-2
name alloc/op
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:failover(*cache.XsyncMap)-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:*cache.XsyncMap-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:xsync.Map-base-2 3.00B ± 0%
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 3.00B ± 0%
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 4.00B ± 0%
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 7.00B ± 0%
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 39.0B ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 43.0B ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 61.6B ±28%
_concurrent/c1000000:g2:w10.00%:failover(*cache.XsyncMap)-2 48.0B ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 24.0B ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 46.6B ±91%
_concurrent/c1000000:g2:w10.00%:*cache.XsyncMap-2 29.0B ± 0%
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 29.2B ±37%
_concurrent/c1000000:g2:w10.00%:xsync.Map-base-2 21.0B ± 0%
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 24.0B ± 0%
_ShardedByteMap_concurrent-2 3.00B ± 0%
_Failover_noSyncRead-2 0.00B
_FailoverSyncRead-2 160B ± 0%
_FailoverAlwaysBuild-2 447B ± 0%
ShardedMap_Dump-2 846B ± 1%
name allocs/op
_concurrent/c10000:g1:w0.00%:failover(*cache.ShardedMap)-2 0.00
_concurrent/c10000:g2:w0.00%:failover(*cache.ShardedMap)-2 0.00
_concurrent/c10000:g2:w0.00%:failover(*cache.SyncMap)-2 0.00
_concurrent/c10000:g2:w0.00%:failover(*cache.XsyncMap)-2 0.00
_concurrent/c10000:g2:w0.00%:*cache.ShardedMap-2 0.00
_concurrent/c10000:g2:w0.00%:*cache.SyncMap-2 0.00
_concurrent/c10000:g2:w0.00%:*cache.XsyncMap-2 0.00
_concurrent/c10000:g2:w0.00%:sync.Map-base-2 0.00
_concurrent/c10000:g2:w0.00%:xsync.Map-base-2 0.00
_concurrent/c10000:g2:w0.00%:shardedMap-base-2 0.00
_concurrent/c10000:g2:w0.10%:failover(*cache.ShardedMap)-2 0.00
_concurrent/c10000:g2:w1.00%:failover(*cache.ShardedMap)-2 1.00 ± 0%
_concurrent/c10000:g2:w10.00%:failover(*cache.ShardedMap)-2 1.00 ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.ShardedMap)-2 1.00 ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.SyncMap)-2 2.00 ± 0%
_concurrent/c1000000:g2:w10.00%:failover(*cache.XsyncMap)-2 2.00 ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.ShardedMap-2 1.00 ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.SyncMap-2 1.00 ± 0%
_concurrent/c1000000:g2:w10.00%:*cache.XsyncMap-2 1.00 ± 0%
_concurrent/c1000000:g2:w10.00%:sync.Map-base-2 1.00 ± 0%
_concurrent/c1000000:g2:w10.00%:xsync.Map-base-2 1.00 ± 0%
_concurrent/c1000000:g2:w10.00%:shardedMap-base-2 1.00 ± 0%
_ShardedByteMap_concurrent-2 0.00
_Failover_noSyncRead-2 0.00
_FailoverSyncRead-2 3.00 ± 0%
_FailoverAlwaysBuild-2 11.0 ± 0%
ShardedMap_Dump-2 13.0 ± 0%