fiatjaf
4dcadd4d88
update go version so we can use the new benchmarking helper.
2025-03-13 18:57:30 -03:00
fiatjaf
cecc71cd81
fix and improve envelope stuff again, deal with messages as strings on all envelope parsing steps.
2025-03-12 00:18:11 -03:00
fiatjaf
a37dd05344
remove simdjson because sonic is just better.
2025-03-07 21:49:48 -03:00
fiatjaf
8d7e854779
some fixes to sonic and make it faster by reusing arrays.
...
BenchmarkParseMessage/relay/jsonstdlib-4 216 5651451 ns/op
BenchmarkParseMessage/relay/easyjson-4 313 3703457 ns/op
BenchmarkParseMessage/relay/simdjson-4 469 2606309 ns/op
BenchmarkParseMessage/relay/sonic-4 966 1268594 ns/op
BenchmarkParseMessage/client/jsonstdlib-4 216 5524239 ns/op
BenchmarkParseMessage/client/easyjson-4 422 2756370 ns/op
BenchmarkParseMessage/client/simdjson-4 519 2298477 ns/op
BenchmarkParseMessage/client/sonic-4 644 1860583 ns/op
2025-03-07 15:38:22 -03:00
fiatjaf
39bde22639
sonic ast visitor approach. now we're getting faster.
...
BenchmarkParseMessage/relay/jsonstdlib-4 206 8630635 ns/op
BenchmarkParseMessage/relay/easyjson-4 278 4311793 ns/op
BenchmarkParseMessage/relay/simdjson-4 422 2943387 ns/op
BenchmarkParseMessage/relay/sonic-4 849 1576884 ns/op
BenchmarkParseMessage/client/jsonstdlib-4 196 6140585 ns/op
BenchmarkParseMessage/client/easyjson-4 385 2826706 ns/op
BenchmarkParseMessage/client/simdjson-4 405 2628675 ns/op
BenchmarkParseMessage/client/sonic-4 552 2413731 ns/op
2025-03-07 11:03:09 -03:00
fiatjaf
c9411a3c5b
depressing sonic json decoder implementation, breakingly force COUNT to use a single filter, reorganize envelope tests.
2025-03-06 19:34:36 -03:00
fiatjaf
4fb6fcd9a2
make simdjson great again.
...
now it is generally a little faster than the easyjson approach.
goos: linux
goarch: amd64
pkg: github.com/nbd-wtf/go-nostr
cpu: AMD Ryzen 3 3200G with Radeon Vega Graphics
BenchmarkParseMessage/stdlib-4 90 15616341 ns/op
BenchmarkParseMessage/easyjson-4 110 11306466 ns/op
BenchmarkParseMessage/simdjson-4 162 7779856 ns/op
PASS
ok github.com/nbd-wtf/go-nostr 5.547s
2025-03-05 23:56:15 -03:00
fiatjaf
a82780e82e
fix these simdjson benchmarks so others can run them.
2025-02-26 17:12:49 -03:00
fiatjaf
c82b0831e2
depressing simdjson-go benchmarks.
2025-02-25 18:18:31 -03:00