Closed
Description
I tried this code:
const SHIFTVALUE : i64 = 10000000000i64;
fn main() {
fn shiftleft(a : i64, b : i64) -> i64 {
a << b
}
assert_eq!(shiftleft(black_box(SHIFTVALUE), black_box(2)), SHIFTVALUE << 2);
}
Nightly fails running on MIPS emulator
assertion left == right
failed
left: 35705032704
right: 40000000000
Stable succeeds
Looks like the top and bottom dwords are mixed up
target is mips-unknown-linux-musl
emulator is qemu-mips-static
Metadata
Metadata
Assignees
Labels
Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.Category: This is a bug.Issue: A soundness hole (worst kind of bug), see: https://en.wikipedia.org/wiki/SoundnessTarget: MIPS processorsMedium priorityRelevant to the compiler team, which will review and decide on the PR/issue.