Batch size = 400
Keys are random.
See the results below.
Batch size = 400
Keys are random.
See the results below.
$ make write-large-hurry | |
go test -bench PutLarge -benchtime 10s | |
testing: warning: no tests to run | |
PASS | |
BenchmarkPutLarge_BoltDB-4 write_test.go:73: bench put LARGE (8MB), take 1 (n=1) | |
write_test.go:114: last put took: 60.895001ms | |
write_test.go:115: last key: 52fdfc072182654f163f5f0f9a621d72 | |
write_test.go:164: depth: 1, branch pg: 0, leaf pg: 1, entries: 1 | |
write_test.go:170: gc: 229.497µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 40MB | |
write_test.go:70: take 1 (n=1) done in 86.730452ms | |
write_test.go:73: bench put LARGE (8MB), take 2 (n=100) | |
write_test.go:114: last put took: 3.624063431s | |
write_test.go:115: last key: 136385cdc838f0bdd4c812f042577410 | |
write_test.go:164: depth: 2, branch pg: 1, leaf pg: 49, entries: 100 | |
write_test.go:170: gc: 10.450753ms | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 5656MB | |
write_test.go:70: take 2 (n=100) done in 3.81420975s | |
write_test.go:73: bench put LARGE (8MB), take 3 (n=500) | |
write_test.go:114: last put took: 24.137679859s | |
write_test.go:115: last key: dccc016d5895b2121ba4066e44d694f6 | |
write_test.go:164: depth: 3, branch pg: 5, leaf pg: 207, entries: 500 | |
write_test.go:170: gc: 234.08392ms | |
write_test.go:173: mem: heap 17MB/16MB, alloc total 41829MB | |
write_test.go:70: take 3 (n=500) done in 1m12.26475639s | |
500 144517672 ns/op 58.05 MB/s 75859684 B/op 60 allocs/op | |
ok github.com/zenhotels/lmdb-go/lmdb/bench_boltdb 76.507s |
$ make write-hurry | |
go test -bench PutSmall -benchtime 10s | |
testing: warning: no tests to run | |
PASS | |
BenchmarkPutSmall_BoltDB-4 write_test.go:60: bench put SMALL (8KB), take 1 (n=1) | |
write_test.go:114: last put took: 722.342µs | |
write_test.go:115: last key: 52fdfc072182654f163f5f0f9a621d72 | |
write_test.go:164: depth: 1, branch pg: 0, leaf pg: 1, entries: 1 | |
write_test.go:170: gc: 220.937µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 24MB | |
write_test.go:57: take 1 (n=1) done in 1.839494ms | |
write_test.go:60: bench put SMALL (8KB), take 2 (n=100) | |
write_test.go:114: last put took: 4.695413ms | |
write_test.go:115: last key: 136385cdc838f0bdd4c812f042577410 | |
write_test.go:164: depth: 2, branch pg: 1, leaf pg: 49, entries: 100 | |
write_test.go:170: gc: 299.109µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 29MB | |
write_test.go:57: take 2 (n=100) done in 7.887591ms | |
write_test.go:60: bench put SMALL (8KB), take 3 (n=10000) | |
write_test.go:114: last put took: 43.109867ms | |
write_test.go:115: last key: 99e97542e2075290412a71cf6d8d885f | |
write_test.go:164: depth: 3, branch pg: 61, leaf pg: 3444, entries: 10000 | |
write_test.go:170: gc: 603.775µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 430MB | |
write_test.go:57: take 3 (n=10000) done in 1.051686402s | |
write_test.go:60: bench put SMALL (8KB), take 4 (n=200000) | |
write_test.go:114: last put took: 64.00424ms | |
write_test.go:115: last key: 111bd71df0d04914f46d5f9b05a78285 | |
write_test.go:164: depth: 4, branch pg: 1186, leaf pg: 68558, entries: 200000 | |
write_test.go:170: gc: 2.651512ms | |
write_test.go:173: mem: heap 9MB/8MB, alloc total 10545MB | |
write_test.go:57: take 4 (n=200000) done in 31.755373425s | |
200000 158775 ns/op 51.59 MB/s 53032 B/op 19 allocs/op | |
ok github.com/zenhotels/lmdb-go/lmdb/bench_boltdb 32.846s |
$ make write-large | |
go test -bench PutLarge -benchtime 20s | |
testing: warning: no tests to run | |
PASS | |
BenchmarkPutLarge_BoltDB-4 write_test.go:73: bench put LARGE (8MB), take 1 (n=1) | |
write_test.go:114: last put took: 34.497881ms | |
write_test.go:115: last key: 52fdfc072182654f163f5f0f9a621d72 | |
write_test.go:164: depth: 1, branch pg: 0, leaf pg: 1, entries: 1 | |
write_test.go:170: gc: 201.81µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 40MB | |
write_test.go:70: take 1 (n=1) done in 59.00831ms | |
write_test.go:73: bench put LARGE (8MB), take 2 (n=100) | |
write_test.go:114: last put took: 4.296457412s | |
write_test.go:115: last key: 136385cdc838f0bdd4c812f042577410 | |
write_test.go:164: depth: 2, branch pg: 1, leaf pg: 49, entries: 100 | |
write_test.go:170: gc: 46.54619ms | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 5656MB | |
write_test.go:70: take 2 (n=100) done in 4.433888421s | |
write_test.go:73: bench put LARGE (8MB), take 3 (n=1000) | |
write_test.go:114: last put took: 1m19.32278851s | |
write_test.go:115: last key: f4164168d965a2c0fb9cc8c73d9e776e | |
write_test.go:164: depth: 3, branch pg: 6, leaf pg: 367, entries: 1000 | |
write_test.go:170: gc: 217.25258ms | |
write_test.go:173: mem: heap 56MB/56MB, alloc total 70635MB | |
write_test.go:70: take 3 (n=1000) done in 3m52.755437879s | |
1000 232746435 ns/op 36.04 MB/s 68134752 B/op 88 allocs/op | |
ok github.com/zenhotels/lmdb-go/lmdb/bench_boltdb 237.701s |
$ make write | |
go test -bench PutSmall -benchtime 20s | |
testing: warning: no tests to run | |
PASS | |
BenchmarkPutSmall_BoltDB-4 write_test.go:60: bench put SMALL (8KB), take 1 (n=1) | |
write_test.go:114: last put took: 619.343µs | |
write_test.go:115: last key: 52fdfc072182654f163f5f0f9a621d72 | |
write_test.go:164: depth: 1, branch pg: 0, leaf pg: 1, entries: 1 | |
write_test.go:170: gc: 152.674µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 24MB | |
write_test.go:57: take 1 (n=1) done in 1.570061ms | |
write_test.go:60: bench put SMALL (8KB), take 2 (n=100) | |
write_test.go:114: last put took: 4.546017ms | |
write_test.go:115: last key: 136385cdc838f0bdd4c812f042577410 | |
write_test.go:164: depth: 2, branch pg: 1, leaf pg: 49, entries: 100 | |
write_test.go:170: gc: 276.003µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 29MB | |
write_test.go:57: take 2 (n=100) done in 7.669449ms | |
write_test.go:60: bench put SMALL (8KB), take 3 (n=10000) | |
write_test.go:114: last put took: 32.728463ms | |
write_test.go:115: last key: 99e97542e2075290412a71cf6d8d885f | |
write_test.go:164: depth: 3, branch pg: 61, leaf pg: 3444, entries: 10000 | |
write_test.go:170: gc: 495.819µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 430MB | |
write_test.go:57: take 3 (n=10000) done in 839.104854ms | |
write_test.go:60: bench put SMALL (8KB), take 4 (n=300000) | |
write_test.go:114: last put took: 151.282074ms | |
write_test.go:115: last key: 312644a6d87884693ce7655ca8135b0f | |
write_test.go:164: depth: 4, branch pg: 1825, leaf pg: 102792, entries: 300000 | |
write_test.go:170: gc: 993.95µs | |
write_test.go:173: mem: heap 9MB/9MB, alloc total 15991MB | |
write_test.go:57: take 4 (n=300000) done in 1m20.760192946s | |
300000 269198 ns/op 30.43 MB/s 54389 B/op 20 allocs/op | |
ok github.com/zenhotels/lmdb-go/lmdb/bench_boltdb 81.640s |
$ make write-large-quick | |
go test -bench PutLarge -benchtime 5s | |
testing: warning: no tests to run | |
PASS | |
BenchmarkPutLarge_BoltDB-4 write_test.go:73: bench put LARGE (8MB), take 1 (n=1) | |
write_test.go:114: last put took: 232.66152ms | |
write_test.go:115: last key: 52fdfc072182654f163f5f0f9a621d72 | |
write_test.go:164: depth: 1, branch pg: 0, leaf pg: 1, entries: 2 | |
write_test.go:170: gc: 234.662µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 40MB | |
write_test.go:70: take 1 (n=1) done in 235.683686ms | |
write_test.go:73: bench put LARGE (8MB), take 2 (n=50) | |
write_test.go:114: last put took: 1.673853391s | |
write_test.go:115: last key: b546d313c8a3b4c1c0e05447f4ba370e | |
write_test.go:164: depth: 2, branch pg: 1, leaf pg: 24, entries: 50 | |
write_test.go:170: gc: 3.238083ms | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 2456MB | |
write_test.go:70: take 2 (n=50) done in 1.787927834s | |
write_test.go:73: bench put LARGE (8MB), take 3 (n=300) | |
write_test.go:114: last put took: 21.484019917s | |
write_test.go:115: last key: 0fc91ad9516482bdf6eccd1497954b53 | |
write_test.go:164: depth: 3, branch pg: 4, leaf pg: 149, entries: 300 | |
write_test.go:170: gc: 173.154861ms | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 24074MB | |
write_test.go:70: take 3 (n=300) done in 22.076142519s | |
300 73560234 ns/op 114.04 MB/s 75559256 B/op 25 allocs/op | |
ok github.com/zenhotels/lmdb-go/lmdb/bench_boltdb 24.408s |
$ make write-quick | |
go test -bench PutSmall -benchtime 5s | |
testing: warning: no tests to run | |
PASS | |
BenchmarkPutSmall_BoltDB-4 write_test.go:60: bench put SMALL (8KB), take 1 (n=1) | |
write_test.go:114: last put took: 722.681µs | |
write_test.go:115: last key: 52fdfc072182654f163f5f0f9a621d72 | |
write_test.go:164: depth: 1, branch pg: 0, leaf pg: 1, entries: 1 | |
write_test.go:170: gc: 144.657µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 24MB | |
write_test.go:57: take 1 (n=1) done in 1.748068ms | |
write_test.go:60: bench put SMALL (8KB), take 2 (n=100) | |
write_test.go:114: last put took: 4.299021ms | |
write_test.go:115: last key: 136385cdc838f0bdd4c812f042577410 | |
write_test.go:164: depth: 2, branch pg: 1, leaf pg: 49, entries: 100 | |
write_test.go:170: gc: 293.774µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 29MB | |
write_test.go:57: take 2 (n=100) done in 7.416276ms | |
write_test.go:60: bench put SMALL (8KB), take 3 (n=10000) | |
write_test.go:114: last put took: 47.412106ms | |
write_test.go:115: last key: 99e97542e2075290412a71cf6d8d885f | |
write_test.go:164: depth: 3, branch pg: 61, leaf pg: 3444, entries: 10000 | |
write_test.go:170: gc: 508.867µs | |
write_test.go:173: mem: heap 8MB/8MB, alloc total 430MB | |
write_test.go:57: take 3 (n=10000) done in 984.393117ms | |
write_test.go:60: bench put SMALL (8KB), take 4 (n=100000) | |
write_test.go:114: last put took: 65.199403ms | |
write_test.go:115: last key: a55db4d11540fda305deb4d9071b3e51 | |
write_test.go:164: depth: 4, branch pg: 589, leaf pg: 34329, entries: 100000 | |
write_test.go:170: gc: 1.028261ms | |
write_test.go:173: mem: heap 9MB/8MB, alloc total 5249MB | |
write_test.go:57: take 4 (n=100000) done in 13.855879011s | |
100000 138553 ns/op 59.13 MB/s 50534 B/op 18 allocs/op | |
ok github.com/zenhotels/lmdb-go/lmdb/bench_boltdb 14.871s |