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

[8_13] improve performance when calculating hash of string #333

Merged
merged 2 commits into from
Jun 8, 2024

Conversation

jingkaimori
Copy link
Contributor

Performance

hash(string) is 110%-120% faster than before.

Before

ns/op op/s err% total benchmark
6.86 145,850,216.76 0.7% 0.24 hash of string
59.22 16,887,153.73 1.1% 0.24 hash of larger string

After

ns/op op/s err% total benchmark
6.22 160,754,437.19 0.3% 0.24 hash of string
50.64 19,747,047.60 0.2% 0.24 hash of larger string

@jingkaimori jingkaimori requested a review from da-liii June 8, 2024 07:01
@da-liii da-liii changed the title improve performance when calculating hash of string [8_13] improve performance when calculating hash of string Jun 8, 2024
Copy link
Contributor

@da-liii da-liii left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@da-liii da-liii merged commit 85ba510 into main Jun 8, 2024
12 checks passed
@da-liii da-liii deleted the jingkaimori/string-algorithm branch June 8, 2024 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants