Add PreservedSymbols from LLVM to LTO.
When building with LTO, builtin functions that are defined but whose calls have not been inserted yet, get internalized. We need to prevent these symbols from being internalized at LTO time. Refer to https://reviews.llvm.org/D49434.
This commit is contained in:
parent
6762d64063
commit
a6f7596fb9
4 changed files with 105 additions and 3 deletions
|
|
@ -8,7 +8,7 @@ fn my_panic(_info: &core::panic::PanicInfo) -> ! {
|
|||
|
||||
#[no_mangle]
|
||||
pub fn multer(a: i128, b: i128) -> i128 {
|
||||
// Trigger usage of the __multi3 compiler intrinsic which then leads to an imported
|
||||
// panic function in case of a bug. We verify that no imports exist in our verifier.
|
||||
// Trigger usage of the __multi3 compiler intrinsic which then leads to an imported function
|
||||
// such as panic or __multi3 in case of a bug. We verify that no imports exist in our verifier.
|
||||
a * b
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue