Skip to content

Commit d1b5776

Browse files
author
JkLondon
committed
Add benchmark notice to README with performance improvement details
1 parent 6c3d446 commit d1b5776

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,3 +183,26 @@ specifically declared to merely be
183183

184184
The API of an unstable package may change in subtle ways between minor release versions. But deprecations will be
185185
indicated at least one release in advance and all functionality will remain available through some method.
186+
187+
## Benchmark Notice
188+
It's noticed that GODEBUG=cgocheck=0 significantly increase mdbx-go perfomance (but be aware of misuse, it's
189+
cgoCheckPointer disable, so of course it could be dangerous DIOR)
190+
```shell
191+
goos: darwin
192+
goarch: arm64
193+
pkg: github.com/erigontech/mdbx-go/mdbx
194+
cpu: Apple M3 Max
195+
│ old.txt │ new.txt │
196+
│ sec/op │ sec/op vs base │
197+
Cursor_Set_OneKey-16 57.58n ± 2% 40.53n ± 0% -29.61% (p=0.000 n=10)
198+
199+
│ old.txt │ new.txt │
200+
│ B/op │ B/op vs base │
201+
Cursor_Set_OneKey-16 0.000 ± 0% 0.000 ± 0% ~ (p=1.000 n=10) ¹
202+
¹ all samples are equal
203+
204+
│ old.txt │ new.txt │
205+
│ allocs/op │ allocs/op vs base │
206+
Cursor_Set_OneKey-16 0.000 ± 0% 0.000 ± 0% ~ (p=1.000 n=10) ¹
207+
¹ all samples are equal
208+
```

0 commit comments

Comments
 (0)