Skip to content

perf(lexer): inline handle_byte into read_next_token#15520

Merged
graphite-app[bot] merged 1 commit intomainfrom
11-09-perf_lexer_inline_handle_byte_into_read_next_token_
Nov 9, 2025
Merged

perf(lexer): inline handle_byte into read_next_token#15520
graphite-app[bot] merged 1 commit intomainfrom
11-09-perf_lexer_inline_handle_byte_into_read_next_token_

Conversation

@overlookmotel
Copy link
Member

@overlookmotel overlookmotel commented Nov 9, 2025

Preparatory step for #15513. That PR adds a 2nd callsite for handle_byte. Mark it as #[inline(always)] to make sure it gets inlined in both places.

This was originally part of #15513, but have split it out into a separate PR so that Codspeed's results on #15513 measure the actual substantive change in isolation - to check that change is having the effect I think it is, and that the gain wasn't actually coming from adding #[inline(always)] here. This PR has no effect on performance, so the gain is in #15513.

@github-actions github-actions bot added A-parser Area - Parser C-performance Category - Solution not expected to change functional behavior, only performance labels Nov 9, 2025
Copy link
Member Author

overlookmotel commented Nov 9, 2025


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • 0-merge - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@codspeed-hq
Copy link

codspeed-hq bot commented Nov 9, 2025

CodSpeed Performance Report

Merging #15520 will not alter performance

Comparing 11-09-perf_lexer_inline_handle_byte_into_read_next_token_ (ff4461f) with 11-09-ci_benchmarks_lexer_ensure_next_token_is_inlined_into_lexer_benchmark (fade858)

Summary

✅ 37 untouched

@overlookmotel overlookmotel force-pushed the 11-09-perf_lexer_inline_handle_byte_into_read_next_token_ branch from 81e0aa1 to ff4461f Compare November 9, 2025 16:02
@overlookmotel overlookmotel marked this pull request as ready for review November 9, 2025 16:24
@graphite-app graphite-app bot added the 0-merge Merge with Graphite Merge Queue label Nov 9, 2025
@graphite-app
Copy link
Contributor

graphite-app bot commented Nov 9, 2025

Merge activity

Preparatory step for #15513. That PR adds a 2nd callsite for `handle_byte`. Mark it as `#[inline(always)]` to make sure it gets inlined in both places.

This was originally part of #15513, but have split it out into a separate PR so that Codspeed's results on #15513 measure the actual substantive change in isolation - to check that change is having the effect I think it is, and that the gain wasn't actually coming from adding `#[inline(always)]` here. This PR has no effect on performance, so the gain *is* in #15513.
@graphite-app graphite-app bot force-pushed the 11-09-ci_benchmarks_lexer_ensure_next_token_is_inlined_into_lexer_benchmark branch from fade858 to 0ce9850 Compare November 9, 2025 16:46
@graphite-app graphite-app bot force-pushed the 11-09-perf_lexer_inline_handle_byte_into_read_next_token_ branch from ff4461f to b310c28 Compare November 9, 2025 16:46
@graphite-app graphite-app bot removed the 0-merge Merge with Graphite Merge Queue label Nov 9, 2025
Base automatically changed from 11-09-ci_benchmarks_lexer_ensure_next_token_is_inlined_into_lexer_benchmark to main November 9, 2025 16:52
@graphite-app graphite-app bot merged commit b310c28 into main Nov 9, 2025
22 checks passed
@graphite-app graphite-app bot deleted the 11-09-perf_lexer_inline_handle_byte_into_read_next_token_ branch November 9, 2025 16:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-parser Area - Parser C-performance Category - Solution not expected to change functional behavior, only performance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments