8000 perf(es/lexer): Optimize lexing of numbers with separators by kdy1 · Pull Request #10665 · swc-project/swc · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

perf(es/lexer): Optimize lexing of numbers with separators #10665

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

Merged
merged 11 commits into from
Jun 22, 2025
Merged

Conversation

kdy1
Copy link
Member
@kdy1 kdy1 commented Jun 21, 2025

Description:

str.replace('ascii_char', "") can be specialized.

@kdy1 kdy1 added this to the Planned milestone Jun 21, 2025
@kdy1 kdy1 self-assigned this Jun 21, 2025
Copy link
8000 changeset-bot bot commented Jun 21, 2025

🦋 Changeset detected

Latest commit: e92dd13

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
codspeed-hq bot commented Jun 21, 2025

CodSpeed Performance Report

Merging #10665 will create unknown performance changes

Comparing kdy1/perf-try-7 (e92dd13) with main (cac651b)

Summary

🆕 140 new benchmarks

Benchmarks breakdown

Benchmark BASE HEAD Change
🆕 css/visitor/compare/clone N/A 5.1 ms N/A
🆕 css/visitor/compare/fold_span N/A 6 ms N/A
🆕 css/visitor/compare/fold_span_panic N/A 6 ms N/A
🆕 css/visitor/compare/visit_mut_span N/A 5.4 ms N/A
🆕 css/visitor/compare/visit_mut_span_panic N/A 5.4 ms N/A
🆕 css/lexer/bootstrap_5_1_3 N/A 11.2 ms N/A
🆕 css/lexer/foundation_6_7_4 N/A 9.1 ms N/A
🆕 css/lexer/tailwind_3_1_1 N/A 1.8 ms N/A
🆕 css/parser/bootstrap_5_1_3 N/A 48.6 ms N/A
🆕 css/parser/foundation_6_7_4 N/A 38.4 ms N/A
🆕 css/parser/tailwind_3_1_1 N/A 7.5 ms N/A
🆕 es/codegen/colors N/A 70.1 µs N/A
🆕 es/codegen/large N/A 643.5 µs N/A
🆕 es/codegen/with-parser/colors N/A 167.7 µs N/A
🆕 es/codegen/with-parser/large N/A 1.3 ms N/A
🆕 es/lexer/angular N/A 10.7 ms N/A
🆕 es/lexer/backbone N/A 1.5 ms N/A
🆕 es/lexer/cal-com N/A 30.9 ms N/A
🆕 es/lexer/colors N/A 37.7 µs N/A
🆕 es/lexer/jquery N/A 8.1 ms N/A
... ... ... ... ...

ℹ️ Only the first 20 benchmarks are displayed. Go to the app to view all benchmarks.

@magic-akari
Copy link
Member
magic-akari commented Jun 21, 2025

We should implement our own version of cow_replace.

@kdy1
Copy link
Member Author
kdy1 commented Jun 21, 2025

@magic-akari I made cow-replace crate with dudykr/ddbase#89

kdy1 added a commit to dudykr/ddbase that referenced this pull request Jun 21, 2025
@kdy1 kdy1 force-pushed the kdy1/perf-try-7 branch from 1de1b33 to d9d780f Compare June 21, 2025 22:49
@kdy1 kdy1 marked this pull request as ready for review June 22, 2025 00:04
@kdy1 kdy1 requested review from a team as code owners June 22, 2025 00:04
@kdy1 kdy1 enabled auto-merge (squash) June 22, 2025 00:04
@kdy1 kdy1 disabled auto-merge June 22, 2025 00:20
@kdy1 kdy1 merged commit cac651b into main Jun 22, 2025
166 checks passed
@kdy1 kdy1 deleted the kdy1/perf-try-7 branch June 22, 2025 00:20
@kdy1 kdy1 modified the milestones: Planned, v1.12.6 Jun 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0