Returning from inline asm!
is unsound (always UB, and made worse by MIR inlining).
#1002
Labels
t: bug
Something isn't working
EDIT(@eddyb): updated the title to reflect better understanding of the underlying problem.
The reason the crashes make no sense is because the MIR we get is already broken, having inlined calls to functions that contain
asm!("OpReturnValue")
, which changes meaning to return from the caller, not the callee.If you run into a similar crash, you could try
RUSTGPU_RUSTFLAGS=-Zmir-opt-level=0
as a workaround for nowWhen compiling this shader (with capability
Int64
enabled)The compiler panics with the following callstack:
Culprit was found to be a the
AccelerationStructure::from_u64()
call, using apush_constant
input.Interestingly, if the input doesn't come from a push constant (but from, say, a constant
0_u64
), you'll get this:The text was updated successfully, but these errors were encountered: