diff options
| author | Matthew Maurer <mmaurer@google.com> | 2025-01-07 00:53:42 +0000 |
|---|---|---|
| committer | Matthew Maurer <mmaurer@google.com> | 2025-01-07 01:02:22 +0000 |
| commit | fc32dd49cb70c4b113353c7a060a875f30b9af04 (patch) | |
| tree | 8025e61360d150ae0be84216f7a0b9885c36ce47 /compiler/rustc_codegen_gcc | |
| parent | 243d2ca4db6f96d2d18aaf3a2381251d38eb6b0b (diff) | |
| download | rust-fc32dd49cb70c4b113353c7a060a875f30b9af04.tar.gz rust-fc32dd49cb70c4b113353c7a060a875f30b9af04.zip | |
llvm: Ignore error value that is always false
See llvm/llvm-project#121851 For LLVM 20+, this function (`renameModuleForThinLTO`) has no return value. For prior versions of LLVM, this never failed, but had a signature which allowed an error value people were handling.
Diffstat (limited to 'compiler/rustc_codegen_gcc')
| -rw-r--r-- | compiler/rustc_codegen_gcc/src/back/lto.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/compiler/rustc_codegen_gcc/src/back/lto.rs b/compiler/rustc_codegen_gcc/src/back/lto.rs index ed92f9c5241..f7173d4d2ff 100644 --- a/compiler/rustc_codegen_gcc/src/back/lto.rs +++ b/compiler/rustc_codegen_gcc/src/back/lto.rs @@ -660,9 +660,7 @@ pub unsafe fn optimize_thin_module( { let _timer = cgcx.prof.generic_activity_with_arg("LLVM_thin_lto_rename", thin_module.name()); - if !llvm::LLVMRustPrepareThinLTORename(thin_module.shared.data.0, llmod, target) { - return Err(write::llvm_err(&dcx, LlvmError::PrepareThinLtoModule)); - } + unsafe { llvm::LLVMRustPrepareThinLTORename(thin_module.shared.data.0, llmod, target) }; save_temp_bitcode(cgcx, &module, "thin-lto-after-rename"); } |
