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

Improve performance of ParseUfloat #1865

Merged
merged 5 commits into from
Sep 22, 2024

Commits on Sep 14, 2024

  1. Improve performance of ParseUfloat function

    Replaced `offset` handling logic with more efficient math.Pow10 based calculation.
    
    goos: linux
    goarch: amd64
    pkg: github.com/valyala/fasthttp
    cpu: Intel(R) Core(TM) i7-4790 CPU @ 3.60GHz
                  │   old.txt   │           new.txt           │
                  │   sec/op    │   sec/op     vs base        │
    ParseUfloat-8   44.22n ± 0%   31.06n ± 0%  -29.76% (n=50)
    ksw2000 committed Sep 14, 2024
    Configuration menu
    Copy the full SHA
    4865258 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7e44b13 View commit details
    Browse the repository at this point in the history

Commits on Sep 22, 2024

  1. Configuration menu
    Copy the full SHA
    6fe140c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    58c2ed8 View commit details
    Browse the repository at this point in the history
  3. fix: lint error

    ksw2000 committed Sep 22, 2024
    Configuration menu
    Copy the full SHA
    bc0a3dc View commit details
    Browse the repository at this point in the history