You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@datasketches.apache.org by "proost (via GitHub)" <gi...@apache.org> on 2025/09/27 06:39:08 UTC
[PR] perf: use slices.sort [datasketches-go]
proost opened a new pull request, #45:
URL: https://github.com/apache/datasketches-go/pull/45
use slices.SortFunc.
It is generally recommended in [Docs](https://pkg.go.dev/sort#Slice)
Benchmark:
```
# Sort Performance Comparison For "Row": sort.Slice vs slices.SortFunc
## Benchmark Results
goos: darwin
goarch: arm64
pkg: github.com/apache/datasketches-go/frequencies
cpu: Apple M1 Pro
BenchmarkSortSlice
BenchmarkSortSlice/size=10
BenchmarkSortSlice/size=10-10 7209180 160.6 ns/op 136 B/op 3 allocs/op
BenchmarkSortSlice/size=100
BenchmarkSortSlice/size=100-10 574626 2021 ns/op 952 B/op 3 allocs/op
BenchmarkSortSlice/size=1000
BenchmarkSortSlice/size=1000-10 27068 43068 ns/op 8248 B/op 3 allocs/op
BenchmarkSortSlice/size=10000
BenchmarkSortSlice/size=10000-10 1363 864653 ns/op 81976 B/op 3 allocs/op
goos: darwin
goarch: arm64
pkg: github.com/apache/datasketches-go/frequencies
cpu: Apple M1 Pro
BenchmarkSlicesSortFunc
BenchmarkSlicesSortFunc/size=10
BenchmarkSlicesSortFunc/size=10-10 9643902 114.1 ns/op 80 B/op 1 allocs/op
BenchmarkSlicesSortFunc/size=100
BenchmarkSlicesSortFunc/size=100-10 667498 1730 ns/op 896 B/op 1 allocs/op
BenchmarkSlicesSortFunc/size=1000
BenchmarkSlicesSortFunc/size=1000-10 27518 41382 ns/op 8192 B/op 1 allocs/op
BenchmarkSlicesSortFunc/size=10000
BenchmarkSlicesSortFunc/size=10000-10 1582 758889 ns/op 81920 B/op 1 allocs/op
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@datasketches.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@datasketches.apache.org
For additional commands, e-mail: dev-help@datasketches.apache.org
Re: [PR] perf: use slices.sort [datasketches-go]
Posted by "freakyzoidberg (via GitHub)" <gi...@apache.org>.
freakyzoidberg commented on PR #45:
URL: https://github.com/apache/datasketches-go/pull/45#issuecomment-3342788097
Thanks a lot !
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@datasketches.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@datasketches.apache.org
For additional commands, e-mail: dev-help@datasketches.apache.org
Re: [PR] perf: use slices.sort [datasketches-go]
Posted by "freakyzoidberg (via GitHub)" <gi...@apache.org>.
freakyzoidberg merged PR #45:
URL: https://github.com/apache/datasketches-go/pull/45
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@datasketches.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@datasketches.apache.org
For additional commands, e-mail: dev-help@datasketches.apache.org