diff options
| author | bors <bors@rust-lang.org> | 2022-11-09 04:43:43 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2022-11-09 04:43:43 +0000 |
| commit | 91385d5776a381b7fd24c0be41879f15fc834e43 (patch) | |
| tree | 81cba8034ed39a068537dff105f1c69fbef5c9b2 /compiler/rustc_codegen_llvm/src | |
| parent | bc2504a83ca6ee8f6717dedd0721b90ffcbe1300 (diff) | |
| parent | 6c021cf07d8e47d33b8d764b9505d3442177e241 (diff) | |
| download | rust-91385d5776a381b7fd24c0be41879f15fc834e43.tar.gz rust-91385d5776a381b7fd24c0be41879f15fc834e43.zip | |
Auto merge of #104179 - Manishearth:rollup-yvsx5hh, r=Manishearth
Rollup of 7 pull requests Successful merges: - #100508 (avoid making substs of type aliases late bound when used as fn args) - #101381 (Test that target feature mix up with homogeneous floats is sound) - #103353 (Fix Access Violation when using lld & ThinLTO on windows-msvc) - #103521 (Avoid possible infinite loop when next_point reaching the end of file) - #103559 (first move on a nested span_label) - #103778 (Update several crates for improved support of the new targets) - #103827 (Properly remap and check for substs compatibility in `confirm_impl_trait_in_trait_candidate`) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
| -rw-r--r-- | compiler/rustc_codegen_llvm/src/consts.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_llvm/src/consts.rs b/compiler/rustc_codegen_llvm/src/consts.rs index dd3c43ba5ca..bf5ac4e503e 100644 --- a/compiler/rustc_codegen_llvm/src/consts.rs +++ b/compiler/rustc_codegen_llvm/src/consts.rs @@ -19,6 +19,7 @@ use rustc_middle::mir::mono::MonoItem; use rustc_middle::ty::layout::LayoutOf; use rustc_middle::ty::{self, Instance, Ty}; use rustc_middle::{bug, span_bug}; +use rustc_session::config::Lto; use rustc_target::abi::{ AddressSpace, Align, HasDataLayout, Primitive, Scalar, Size, WrappingRange, }; @@ -303,7 +304,8 @@ impl<'ll> CodegenCx<'ll, '_> { // ThinLTO can't handle this workaround in all cases, so we don't // emit the attrs. Instead we make them unnecessary by disallowing // dynamic linking when linker plugin based LTO is enabled. - !self.tcx.sess.opts.cg.linker_plugin_lto.enabled(); + !self.tcx.sess.opts.cg.linker_plugin_lto.enabled() && + self.tcx.sess.lto() != Lto::Thin; // If this assertion triggers, there's something wrong with commandline // argument validation. |
