mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 14:55:26 +00:00
Rollup merge of #97969 - inglorion:prelinkpasses, r=nikic
Make -Cpasses= only apply to pre-link optimization This change causes passes specified in -Cpasses= to be applied only during pre-link optimization, not during LTO. This avoids such passes running multiple times, which they may not be designed for. Fixes https://github.com/rust-lang/rust/issues/97713
This commit is contained in:
commit
b3d8e71cf1
@ -463,7 +463,7 @@ pub(crate) unsafe fn optimize_with_new_llvm_pass_manager(
|
||||
let llvm_selfprofiler =
|
||||
llvm_profiler.as_mut().map(|s| s as *mut _ as *mut c_void).unwrap_or(std::ptr::null_mut());
|
||||
|
||||
let extra_passes = config.passes.join(",");
|
||||
let extra_passes = if !is_lto { config.passes.join(",") } else { "".to_string() };
|
||||
|
||||
let llvm_plugins = config.llvm_plugins.join(",");
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user