-
Notifications
You must be signed in to change notification settings - Fork 13.1k
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
Fix LLVM assert with write_volatile #32233
Conversation
let val = if type_is_immediate(bcx.ccx(), tp_ty) { | ||
from_arg_ty(bcx, llargs[1], tp_ty) | ||
} else { | ||
Load(bcx, from_arg_ty(bcx, llargs[1], tp_ty)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't need to transform llargs[1]
, if it's not immediate then it's a pointer to the value you want (Load
wouldn't work otherwise anyway).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
llargs[1]
is the value that needs to be stored. llargs[0]
is the pointer to the store destination.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If not immediate, then it's passed indirectly and llargs[1]
is a pointer to the value that needs to be stored.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh nevermind, I see what the problem is.
@bors r+ |
📌 Commit 86fd5a0 has been approved by |
Fix LLVM assert with write_volatile Fixes #29663
Fixes #29663