8000 perf(swc_common): Remove `char_indices` calls by bvanjoi · Pull Request #10541 · swc-project/swc · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

perf(swc_common): Remove char_indices calls #10541

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 2 commits into from
Jun 2, 2025
Merged

Conversation

bvanjoi
Copy link
Contributor
@bvanjoi bvanjoi commented Jun 2, 2025

Let's examine whether there are any potential improvements.

@bvanjoi bvanjoi requested a review from a team as a code owner June 2, 2025 13:31
Copy link
changeset-bot bot commented Jun 2, 2025

🦋 Changeset detected

Latest commit: d359585

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

if pred(c) {
last = i + c.len_utf8();
break;
let last = {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Input/find appears unused, can we remove it?

Copy link
Member

Choose a reason for hiding this comment

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

Yeap

Copy link
Member

Choose a reason for hiding this comment

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

But with a separate PR

Copy link
codspeed-hq bot commented Jun 2, 2025

CodSpeed Performance Report

Merging #10541 will improve performances by 2.35%

Comparing bvanjoi:common (d359585) with main (51507bc)

Summary

⚡ 1 improvements
✅ 143 untouched benchmarks

Benchmarks breakdown

Benchmark BASE HEAD Change
es/lints/libs/d3 28.2 ms 27.5 ms +2.35%

@bvanjoi
Copy link
Contributor Author
bvanjoi commented Jun 2, 2025

Shows slight improvement, acceptable for now.

kdy1
kdy1 previously approved these changes Jun 2, 2025
Copy link
Member
@kdy1 kdy1 left a comment

Choose a reason for hiding this comment

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

Thanks!
image

@kdy1 kdy1 changed the title perf(swc/common): rm char_indices perf(swc_common): Remove char_indices calls Jun 2, 2025
@kdy1 kdy1 merged commit 51507bc into swc-project:main Jun 2, 2025
18 checks passed
@kdy1 kdy1 modified the milestones: Planned, Next version Jun 2, 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