We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cca2388 commit bdf7835Copy full SHA for bdf7835
compiler/rustc_codegen_llvm/src/back/lto.rs
@@ -151,7 +151,12 @@ fn get_bitcode_slice_from_object_data(obj: &[u8]) -> Result<&[u8], LtoBitcodeFro
151
return Ok(obj);
152
}
153
match object::read::File::parse(obj) {
154
- Ok(f) => match f.section_by_name(".llvmbc").or_else(|| f.section_by_name(".llvm.lto")) {
+ Ok(f) => match f
155
+ .section_by_name(".llvmbc")
156
+ .or_else(|| f.section_by_name(".llvm.lto"))
157
+ .or_else(|| f.section_by_name("__LLVM,__bitcode\0"))
158
+ .or_else(|| f.section_by_name(".ipa\0"))
159
+ {
160
Some(d) => Ok(d.data().unwrap()),
161
None => Err(LtoBitcodeFromRlib {
162
llvm_err: "Bitcode section not found in object file".to_string(),
0 commit comments