diff options
| author | bors <bors@rust-lang.org> | 2020-11-11 01:18:18 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-11-11 01:18:18 +0000 |
| commit | 38030ffb4e735b26260848b744c0910a5641e1db (patch) | |
| tree | 7cd5b04b2b71157b1112ad1f6fcd01c15db32a75 /compiler/rustc_codegen_llvm/src/llvm_util.rs | |
| parent | cf9cf7c923eb01146971429044f216a3ca905e06 (diff) | |
| parent | fa4d0f232799a4f83490fc6f2d748dbf62c536c9 (diff) | |
| download | rust-38030ffb4e735b26260848b744c0910a5641e1db.tar.gz rust-38030ffb4e735b26260848b744c0910a5641e1db.zip | |
Auto merge of #78920 - jonas-schievink:rollup-w2mjsuh, r=jonas-schievink
Rollup of 14 pull requests Successful merges: - #76765 (Make it more clear what an about async fn's returns when referring to what it returns) - #78574 (Use check-pass instead of build-pass in regions ui test suite) - #78669 (Use check-pass instead of build-pass in some consts ui test suits) - #78847 (Assert that a return place is not used for indexing during integration) - #78854 (Workaround for "could not fully normalize" ICE ) - #78875 (rustc_target: Further cleanup use of target options) - #78887 (Add comments to explain memory usage optimization) - #78890 (comment attribution fix) - #78896 (Clarified description of write! macro) - #78897 (Add missing newline to error message of the default OOM hook) - #78898 (add regression test for #78892) - #78908 ((rustdoc) [src] link for types defined by macros shows invocation, not defintion) - #78910 (Fix links to stabilized versions of some intrinsics) - #78912 (Add macro test for min-const-generics) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/llvm_util.rs')
| -rw-r--r-- | compiler/rustc_codegen_llvm/src/llvm_util.rs | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/compiler/rustc_codegen_llvm/src/llvm_util.rs b/compiler/rustc_codegen_llvm/src/llvm_util.rs index 9c1e1b8fac0..ab70f72dc61 100644 --- a/compiler/rustc_codegen_llvm/src/llvm_util.rs +++ b/compiler/rustc_codegen_llvm/src/llvm_util.rs @@ -46,7 +46,7 @@ fn require_inited() { } unsafe fn configure_llvm(sess: &Session) { - let n_args = sess.opts.cg.llvm_args.len() + sess.target.options.llvm_args.len(); + let n_args = sess.opts.cg.llvm_args.len() + sess.target.llvm_args.len(); let mut llvm_c_strs = Vec::with_capacity(n_args + 1); let mut llvm_args = Vec::with_capacity(n_args + 1); @@ -57,7 +57,7 @@ unsafe fn configure_llvm(sess: &Session) { } let cg_opts = sess.opts.cg.llvm_args.iter(); - let tg_opts = sess.target.options.llvm_args.iter(); + let tg_opts = sess.target.llvm_args.iter(); let sess_args = cg_opts.chain(tg_opts); let user_specified_args: FxHashSet<_> = @@ -84,19 +84,14 @@ unsafe fn configure_llvm(sess: &Session) { if !sess.opts.debugging_opts.no_generate_arange_section { add("-generate-arange-section", false); } - match sess - .opts - .debugging_opts - .merge_functions - .unwrap_or(sess.target.options.merge_functions) - { + match sess.opts.debugging_opts.merge_functions.unwrap_or(sess.target.merge_functions) { MergeFunctions::Disabled | MergeFunctions::Trampolines => {} MergeFunctions::Aliases => { add("-mergefunc-use-aliases", false); } } - if sess.target.target_os == "emscripten" && sess.panic_strategy() == PanicStrategy::Unwind { + if sess.target.os == "emscripten" && sess.panic_strategy() == PanicStrategy::Unwind { add("-enable-emscripten-cxx-exceptions", false); } @@ -215,7 +210,7 @@ fn handle_native(name: &str) -> &str { pub fn target_cpu(sess: &Session) -> &str { let name = match sess.opts.cg.target_cpu { Some(ref s) => &**s, - None => &*sess.target.options.cpu, + None => &*sess.target.cpu, }; handle_native(name) |
