Skip to content
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

perf(semantic): use Atom instead of CompactStr for UnresolvedReferencesStack #4394

Conversation

Dunqing
Copy link
Member

@Dunqing Dunqing commented Jul 21, 2024

Just a try

Copy link

graphite-app bot commented Jul 21, 2024

Your org has enabled the Graphite merge queue for merging into main

Add the label “merge” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix.

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

Copy link
Member Author

Dunqing commented Jul 21, 2024

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

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

Join @Dunqing and the rest of your teammates on Graphite Graphite

Copy link

codspeed-hq bot commented Jul 21, 2024

CodSpeed Performance Report

Merging #4394 will improve performances by 3.63%

Comparing 07-21-perf_semantic_use_atom_instead_of_compactstr_for_unresolved_references (d9315ff) with 07-18-refactor_semantic_remove_name_from_reference (468852f)

Summary

⚡ 1 improvements
✅ 31 untouched benchmarks

Benchmarks breakdown

Benchmark 07-18-refactor_semantic_remove_name_from_reference 07-21-perf_semantic_use_atom_instead_of_compactstr_for_unresolved_references Change
semantic[checker.ts] 99 ms 95.6 ms +3.63%

@Dunqing Dunqing requested a review from overlookmotel July 21, 2024 15:07
@overlookmotel
Copy link
Contributor

Nice! Significant speed-up.

@Dunqing Dunqing closed this Jul 22, 2024
@Dunqing Dunqing force-pushed the 07-21-perf_semantic_use_atom_instead_of_compactstr_for_unresolved_references branch from d9315ff to 468852f Compare July 22, 2024 02:21
@Dunqing Dunqing changed the title perf(semantic): use Atom instead of CompactStr for unresolved_references perf(semantic): use Atom instead of CompactStr for UnresolvedReferencesStack Jul 22, 2024
@Dunqing
Copy link
Member Author

Dunqing commented Jul 22, 2024

Cannot reopen this PR, so I create another PR #4401 instead

overlookmotel pushed a commit that referenced this pull request Jul 22, 2024
…erencesStack` (#4401)

related: #4394

The `UnresolvedReferencesStack` is only used for resolving references, and the `Atom` clone is cheap, So we can safely change `CompactStr`to `Atom`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-semantic Area - Semantic
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants