Skip to content

perf: improve has_tabs_or_newline performance#670

Merged
anonrig merged 1 commit intomainfrom
perf-improve-has-tabs
Jul 6, 2024
Merged

perf: improve has_tabs_or_newline performance#670
anonrig merged 1 commit intomainfrom
perf-improve-has-tabs

Conversation

@anonrig
Copy link
Member

@anonrig anonrig commented May 17, 2024

This seems to slightly reduce the instruction count for url_aggregator, but please run local benchmarks to verify

Before:

  • ada_url -> instructions/url=2.55753k
  • ada_url_aggregator -> instructions/url=2.76077k

After:

  • ada_url -> instructions/url=2.55742k
  • ada_url_aggregator -> instructions/url=2.76044k

@anonrig anonrig requested a review from lemire May 17, 2024 03:34
Copy link
Member

@lemire lemire left a comment

Choose a reason for hiding this comment

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

This is fine, but I bet you can do it with a lambda. Note that you are doing just the NEON routine, you could do the others as well.

I expect that this will not change performance. However, it can make the code more concise, which is good.

@CarlosEduR
Copy link
Member

@anonrig good to go

@anonrig anonrig force-pushed the perf-improve-has-tabs branch from 4c4f35d to 99ae41d Compare July 6, 2024 16:20
@anonrig anonrig requested review from jasnell and lemire July 6, 2024 16:21
@anonrig anonrig merged commit 27a2d93 into main Jul 6, 2024
@anonrig anonrig deleted the perf-improve-has-tabs branch July 6, 2024 16:34
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.

4 participants

Comments