You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The change in #5345 prevented BlockDecoder from escaping to the heap when using
the testkeys.KeySchema, but with the cockroachkvs.KeySchema the key seeker init
func's local BlockDecoder still escaped. This commit updates the key seeker to
call colblk.DecodeColumn directly, which is enough for the Go compiler to avoid
moving the arg to the heap.
```
goos: darwin
goarch: arm64
pkg: github.com/cockroachdb/pebble/cockroachkvs
cpu: Apple M1 Pro
│ old.txt │ new.txt │
│ sec/op │ sec/op vs base │
InitDataBlockMetadata-10 135.5n ± 1% 110.8n ± 0% -18.20% (p=0.002 n=6)
│ old.txt │ new.txt │
│ B/op │ B/op vs base │
InitDataBlockMetadata-10 48.00 ± 0% 0.00 ± 0% -100.00% (p=0.002 n=6)
│ old.txt │ new.txt │
│ allocs/op │ allocs/op vs base │
InitDataBlockMetadata-10 1.000 ± 0% 0.000 ± 0% -100.00% (p=0.002 n=6)
```
0 commit comments