1
Fork 0

Auto merge of #88388 - ldm0:outliner, r=nikic

Revert "Disable the machine outliner by default"

The fix commit is already in the fork: 6c78dbd4ca
Linked:
- https://github.com/rust-lang/rust/issues/85351
- https://github.com/rust-lang/rust/pull/86020
This commit is contained in:
bors 2021-08-28 13:10:26 +00:00
commit 84b0183412

View file

@ -89,13 +89,14 @@ unsafe fn configure_llvm(sess: &Session) {
add("-generate-arange-section", false); add("-generate-arange-section", false);
} }
// FIXME(nagisa): disable the machine outliner by default in LLVM versions 11, where it was // Disable the machine outliner by default in LLVM versions 11 and LLVM
// introduced and up. // version 12, where it leads to miscompilation.
// //
// This should remain in place until https://reviews.llvm.org/D103167 is fixed. If LLVM // Ref:
// has been upgraded since, consider adjusting the version check below to contain an upper // - https://github.com/rust-lang/rust/issues/85351
// bound. // - https://reviews.llvm.org/D103167
if llvm_util::get_version() >= (11, 0, 0) { let llvm_version = llvm_util::get_version();
if llvm_version >= (11, 0, 0) && llvm_version < (13, 0, 0) {
add("-enable-machine-outliner=never", false); add("-enable-machine-outliner=never", false);
} }