Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zstd: Select best match using selection trees #706

Merged
merged 2 commits into from Dec 4, 2022

Commits on Dec 2, 2022

  1. zstd: Select best match using selection trees

    name                              old speed      new speed      delta
    Encoder_EncodeAllSimple/best-8    12.2MB/s ± 1%  13.5MB/s ± 3%  +10.55%  (p=0.000 n=20+19)
    Encoder_EncodeAllSimple4K/best-8  10.5MB/s ± 1%  11.9MB/s ± 1%  +13.52%  (p=0.000 n=20+19)
    
    name                              old alloc/op   new alloc/op   delta
    Encoder_EncodeAllSimple/best-8       18.0B ± 0%     16.0B ± 0%  -11.11%  (p=0.000 n=18+17)
    Encoder_EncodeAllSimple4K/best-8     1.00B ± 0%     1.00B ± 0%     ~     (all equal)
    greatroar committed Dec 2, 2022
    Copy the full SHA
    c69ba37 View commit details
    Browse the repository at this point in the history

Commits on Dec 3, 2022

  1. zstd: Track best match in best encoder by pointer

    As long as matchAt does not return a pointer, escape analysis determines
    that the matches can stay on the stack. This works in Go 1.17, too.
    
    name                              old speed      new speed      delta
    Encoder_EncodeAllSimple/best-8    13.5MB/s ± 3%  15.3MB/s ± 2%  +13.35%  (p=0.000 n=19+19)
    Encoder_EncodeAllSimple4K/best-8  11.9MB/s ± 1%  12.9MB/s ± 0%   +8.38%  (p=0.000 n=19+17)
    
    name                              old alloc/op   new alloc/op   delta
    Encoder_EncodeAllSimple/best-8       16.0B ± 0%     14.0B ± 0%  -12.50%  (p=0.000 n=17+20)
    Encoder_EncodeAllSimple4K/best-8     1.00B ± 0%     1.00B ± 0%     ~     (all equal)
    greatroar committed Dec 3, 2022
    Copy the full SHA
    d1da464 View commit details
    Browse the repository at this point in the history