Skip to content

Commit

Permalink
Rollup merge of #76871 - RalfJung:miri-panic-abort, r=dtolnay
Browse files Browse the repository at this point in the history
support panic=abort in Miri

This is needed for rust-lang/miri#1058 on Windows: we cannot run the inline-assembly versions of `abort`, so fall back to the intrinsic (which Miri supports).
  • Loading branch information
RalfJung committed Sep 20, 2020
2 parents 70f55a7 + 0810c3e commit e5be14c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/panic_abort/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ pub unsafe extern "C" fn __rust_start_panic(_payload: usize) -> u32 {
}
__rust_abort();
}
} else if #[cfg(windows)] {
} else if #[cfg(all(windows, not(miri)))] {
// On Windows, use the processor-specific __fastfail mechanism. In Windows 8
// and later, this will terminate the process immediately without running any
// in-process exception handlers. In earlier versions of Windows, this
Expand Down

0 comments on commit e5be14c

Please sign in to comment.