-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lmdb: fixes for previous commit, now it works.
benchmarks for LMDB: goos: linux goarch: amd64 pkg: github.com/fiatjaf/eventstore/test cpu: AMD Ryzen 3 3200G with Radeon Vega Graphics BenchmarkLMDB/filter/q-0-4 787862 1465 ns/op 1652 B/op 28 allocs/op BenchmarkLMDB/filter/q-1-4 1000000 1271 ns/op 1060 B/op 18 allocs/op BenchmarkLMDB/filter/q-2-4 754543 1754 ns/op 1803 B/op 27 allocs/op BenchmarkLMDB/filter/q-3-4 1000000 1314 ns/op 718 B/op 10 allocs/op BenchmarkLMDB/filter/q-4-4 1000000 1296 ns/op 716 B/op 10 allocs/op BenchmarkLMDB/filter/q-5-4 907354 1317 ns/op 1099 B/op 17 allocs/op BenchmarkLMDB/filter/q-6-4 747927 1823 ns/op 1803 B/op 27 allocs/op BenchmarkLMDB/filter/q-7-4 711120 1824 ns/op 1803 B/op 27 allocs/op BenchmarkLMDB/filter/q-8-4 204600 6072 ns/op 7148 B/op 108 allocs/op BenchmarkLMDB/filter/q-9-4 204714 6193 ns/op 7148 B/op 108 allocs/op BenchmarkLMDB/filter/q-10-4 217402 6015 ns/op 7148 B/op 107 allocs/op BenchmarkLMDB/filter/q-11-4 221179 6032 ns/op 7148 B/op 107 allocs/op BenchmarkLMDB/insert-4 10000 101821 ns/op 73984 B/op 13 allocs/op and before how it was: goos: linux goarch: amd64 pkg: github.com/fiatjaf/eventstore/test cpu: AMD Ryzen 3 3200G with Radeon Vega Graphics BenchmarkLMDB/filter/q-0-4 132798 7966 ns/op 4476 B/op 58 allocs/op BenchmarkLMDB/filter/q-1-4 643911 5815 ns/op 2860 B/op 34 allocs/op BenchmarkLMDB/filter/q-2-4 344509 8224 ns/op 4511 B/op 58 allocs/op BenchmarkLMDB/filter/q-3-4 1000000 20966 ns/op 1967 B/op 20 allocs/op BenchmarkLMDB/filter/q-4-4 signal: killed FAIL github.com/fiatjaf/eventstore/test 128.395s FAIL i.e. it couldn't even complete because some stuff would happen, probably with all the goroutines trying to read from the same disk places or whatever. now it is so much better. weirdly, though, if we run the benchmarks with a fixed number of runs for each, like -benchtime=100x, then both versions will complete everything, and in similar time, so I don't know what to conclude. maybe that the new version performs much better under heavy load? I don't know. this is badger without a fixed number of runs, for comparison: badger 2024/11/18 17:49:39 INFO: All 1 tables opened in 2ms badger 2024/11/18 17:49:39 INFO: Discard stats nextEmptySlot: 0 badger 2024/11/18 17:49:39 INFO: Set nextTxnTs to 20002 badger 2024/11/18 17:49:39 INFO: Deleting empty file: /tmp/eventstore-testbadger/000001.vlog goos: linux goarch: amd64 pkg: github.com/fiatjaf/eventstore/test cpu: AMD Ryzen 3 3200G with Radeon Vega Graphics BenchmarkBadger/filter/q-0-4 49177 93349 ns/op 125044 B/op 1609 allocs/op BenchmarkBadger/filter/q-1-4 signal: killed FAIL github.com/fiatjaf/eventstore/test 61.454s FAIL total failure.
- Loading branch information
Showing
16 changed files
with
41 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../internal/testdata/fuzz/FuzzQuery |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
go test fuzz v1 | ||
uint(200) | ||
uint(50) | ||
uint(13) | ||
uint(8) | ||
uint(2) | ||
uint(0) | ||
uint(1) |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../internal/testdata/fuzz/FuzzQuery |