summaryrefslogtreecommitdiff
path: root/server/flate_test.go
Commit message (Collapse)AuthorAge
* benchmark custom DEFLATE compressoroptiflateraven2026-03-27
BenchmarkNaiveGzip flate_test.go:47: compressed empty to 1043631 bytes flate_test.go:47: compressed debug to 1043939 bytes flate_test.go:47: compressed flat to 1043648 bytes flate_test.go:47: compressed sphere to 4981910 bytes flate_test.go:72: naive gzip compressor completed in 24.744500019s BenchmarkDeflate flate_test.go:47: compressed empty to 13525844 bytes flate_test.go:47: compressed debug to 13526111 bytes flate_test.go:47: compressed flat to 13525852 bytes flate_test.go:47: compressed sphere to 19927269 bytes flate_test.go:77: custom deflate compressor completed in 546.099782ms the standard gzip compressor is almost 40 times slower, but it requires around a tenth of the network bandwidth. so, it would seem that, since the internet is slower than CPUs, standard gzip wins out probably. the custom compressor may gain an advantage if huffman trees are actually implemented. however, I'm going to focus on other things for now.