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: rule matcher allocates only if resource_path is not a valid UTF-8 sequence #7441

Merged
merged 1 commit into from
Aug 5, 2024

Conversation

h-a-n-a
Copy link
Collaborator

@h-a-n-a h-a-n-a commented Aug 5, 2024

Summary

Before:

`resource_path` -> `into_owned` -> `String` (allocation  1)

After:

`resource_path` -- valid UTF-8 -->  `Cow<'s, str>` (no allocation)
                -- invalid UTF-8 -> `Cow<'s, str>` (allocation  1)

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

@github-actions github-actions bot added the team The issue/pr is created by the member of Rspack. label Aug 5, 2024
@github-actions github-actions bot added the release: performance release: performance related release(mr only) label Aug 5, 2024
Copy link

netlify bot commented Aug 5, 2024

Deploy Preview for rspack ready!

Name Link
🔨 Latest commit ef11c10
🔍 Latest deploy log https://app.netlify.com/sites/rspack/deploys/66b091c98182b00008b14258
😎 Deploy Preview https://deploy-preview-7441--rspack.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@h-a-n-a h-a-n-a enabled auto-merge (squash) August 5, 2024 08:59
@h-a-n-a h-a-n-a requested a review from JSerFeng August 5, 2024 08:59
@h-a-n-a h-a-n-a merged commit 921a17d into main Aug 5, 2024
47 checks passed
@h-a-n-a h-a-n-a deleted the perf-match branch August 5, 2024 09:47
@chenjiahan chenjiahan mentioned this pull request Aug 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release: performance release: performance related release(mr only) team The issue/pr is created by the member of Rspack.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants