diff options
| author | Peter Collingbourne <peter@pcc.me.uk> | 2017-04-26 17:53:39 +0000 |
|---|---|---|
| committer | Peter Collingbourne <peter@pcc.me.uk> | 2017-04-26 17:53:39 +0000 |
| commit | fa58f7528e81c1a6d055cd93efe2a2f0364e0a3d (patch) | |
| tree | f4126113b71764527f836220c52235eb39bc7e49 /llvm/test/tools | |
| parent | c9f0a4f1eccf55c1f588c8d7e966c677a1baf781 (diff) | |
| download | bcm5719-llvm-fa58f7528e81c1a6d055cd93efe2a2f0364e0a3d.tar.gz bcm5719-llvm-fa58f7528e81c1a6d055cd93efe2a2f0364e0a3d.zip | |
LTO: Mark undefined module asm symbols as used.
Marking them as used causes them to be considered visible outside of LTO. This
prevents the symbols from being internalized or discarded, either by GlobalDCE
or by summary-based dead stripping in ThinLTO.
This change makes it unnecessary to add these symbols to llvm.compiler.used
in the backend, as the symbols are kept alive by virtue of being external,
so remove the backend code that handles that.
Fixes PR32798.
Differential Revision: https://reviews.llvm.org/D32544
llvm-svn: 301438
Diffstat (limited to 'llvm/test/tools')
| -rw-r--r-- | llvm/test/tools/gold/X86/asm_undefined2.ll | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/test/tools/gold/X86/asm_undefined2.ll b/llvm/test/tools/gold/X86/asm_undefined2.ll index 6cb7a1cf3d0..a170f45a55a 100644 --- a/llvm/test/tools/gold/X86/asm_undefined2.ll +++ b/llvm/test/tools/gold/X86/asm_undefined2.ll @@ -11,8 +11,8 @@ ; RUN: --plugin-opt=thinlto -o %t2 %t.o ; RUN: llvm-dis < %t.o.5.precodegen.bc | FileCheck %s -; Check that foo is properly appended to llvm.compiler.used -; CHECK: @llvm.compiler.used = appending global [1 x i8*] [i8* bitcast (void ()* @foo to i8*)], section "llvm.metadata" +; Check that foo is not internalized +; CHECK: define void @foo target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-unknown-linux-gnu" |

