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

Avoid some allocas in codegen of CastKind::Transmute #109549

Closed
wants to merge 1 commit into from

Conversation

scottmcm
Copy link
Member

@scottmcm scottmcm commented Mar 24, 2023

Now that it's a Cast instead of a Call, thanks to #108442, we don't need to write out the value to a place every time.

For simple cases like transmuting to/from a newtype, we can instead just pass along the immediate SSA value.

@rustbot
Copy link
Collaborator

rustbot commented Mar 24, 2023

r? @lcnr

(rustbot has picked a reviewer for you, use r? to override)

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Mar 24, 2023
@scottmcm scottmcm marked this pull request as draft March 24, 2023 04:31
@scottmcm scottmcm added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 24, 2023
@lcnr
Copy link
Contributor

lcnr commented Mar 24, 2023

r? compiler

@rustbot rustbot assigned b-naber and unassigned lcnr Mar 24, 2023
@b-naber
Copy link
Contributor

b-naber commented Mar 24, 2023

r? @oli-obk

@rustbot rustbot assigned oli-obk and unassigned b-naber Mar 24, 2023
@scottmcm
Copy link
Member Author

I'm going to close this for now, and probably come back to it with a different approach so long as #109556 goes well.

@scottmcm scottmcm closed this Mar 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants