Skip to content

perf(parser): inline common expression parsing paths - #28293

Closed
Boshen wants to merge 4 commits into
codex/parser-lexer-scanningfrom
codex/parser-expression-inlining
Closed

Boshen wants to merge 4 commits into
codex/parser-lexer-scanningfrom
codex/parser-expression-inlining

Conversation

@Boshen

@Boshen Boshen commented Oct 28, 2026

Copy link
Copy Markdown
Member

Inline common expression parsing paths to reduce call overhead.

Stacked on #28292. AI-assisted implementation.

Use `zmij_ecma` to reduce float-formatting time while preserving
ECMAScript output. Local Apple M4 Pro measurements showed 21–66% less
conversion time and about 18% less time generating synthetic
numeric-heavy JavaScript; real-world bundles were roughly unchanged.

AI-assisted with Codex.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-28T15:17:22.441514Z aef447f PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions github-actions Bot added the A-parser Area - JS/TS parsing and syntax errors, oxc_parser label Oct 28, 2026
@Boshen
Boshen marked this pull request as draft October 28, 2026 15:18
@codspeed

codspeed Bot commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Merging this PR will improve performance by 10.38%

1 warning

⚠️ Base and head ran on different runner types

Some benchmarks with significant performance changes were compared across different runner types, so the changes might not come from the code. Run base and head on the same runner type, or use CodSpeed Macro Runners for more stable results.

Learn more about Macro Runners

Open the report in CodSpeed to investigate

⚡ 4 improved benchmarks
✅ 83 untouched benchmarks
⏩ 9 skipped benchmarks1

Performance Changes

Mode Benchmark BASE HEAD Efficiency
⚡ CPU Simulation parser[App.tsx] 17.2 ms 15.4 ms +11.21%
⚡ CPU Simulation parser[binder.ts] 6.8 ms 6.2 ms +10.84%
⚡ CPU Simulation parser[react.development.js] 2.7 ms 2.4 ms +10.51%
⚡ CPU Simulation parser[kitchen-sink.tsx] 47.4 ms 43.5 ms +8.97%

Tip

Curious why performance improved? Comment @codspeedbot explain why performance improved on this PR, or directly use the CodSpeed MCP with your agent.


Comparing codex/parser-expression-inlining (ae2ce96) with codex/parser-lexer-scanning (92cf70b)

Open in CodSpeed

Footnotes

  1. 9 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

@Boshen
Boshen force-pushed the codex/parser-expression-inlining branch from aef447f to ae2ce96 Compare October 28, 2026 16:52
@Boshen
Boshen force-pushed the codex/parser-lexer-scanning branch 2 times, most recently from 92cf70b to 600f612 Compare October 28, 2026 18:02
@Boshen Boshen closed this Oct 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-parser Area - JS/TS parsing and syntax errors, oxc_parser

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant