forked from OSchip/llvm-project
parent
57e61231ad
commit
5aafbac081
|
@ -1,9 +1,6 @@
|
|||
; RUN: llvm-as %S/only-needed-named-metadata.ll -o %t.bc
|
||||
; RUN: llvm-as %S/Inputs/only-needed-named-metadata.ll -o %t2.bc
|
||||
|
||||
; Without -only-needed we should lazy link linkonce globals, and the
|
||||
; metadata reference should not cause them to be linked.
|
||||
; RUN: llvm-link -S %t2.bc %t.bc | FileCheck %s
|
||||
; RUN: llvm-link -S %S/Inputs/only-needed-named-metadata.ll %S/only-needed-named-metadata.ll | FileCheck %s
|
||||
; CHECK-NOT:@U_linkonce
|
||||
; CHECK-NOT:@unused_linkonce()
|
||||
|
||||
|
@ -13,8 +10,8 @@
|
|||
; which are illegal for aliases and globals in comdats.
|
||||
; Note that doing -only-needed with the comdat shown below leads to a only
|
||||
; part of the comdat group being linked, which is not technically correct.
|
||||
; RUN: llvm-link -S -only-needed %t2.bc %t.bc | FileCheck %s -check-prefix=ONLYNEEDED
|
||||
; RUN: llvm-link -S -internalize -only-needed %t2.bc %t.bc | FileCheck %s -check-prefix=ONLYNEEDED
|
||||
; RUN: llvm-link -S -only-needed %S/Inputs/only-needed-named-metadata.ll %S/only-needed-named-metadata.ll | FileCheck %s -check-prefix=ONLYNEEDED
|
||||
; RUN: llvm-link -S -internalize -only-needed %S/Inputs/only-needed-named-metadata.ll %S/only-needed-named-metadata.ll | FileCheck %s -check-prefix=ONLYNEEDED
|
||||
; ONLYNEEDED-NOT:@U
|
||||
; ONLYNEEDED-NOT:@U_linkonce
|
||||
; ONLYNEEDED-NOT:@unused()
|
||||
|
@ -29,7 +26,7 @@
|
|||
; Test -only-needed link with the modules preserved instead of freeing to
|
||||
; catch any cross-module references to metadata, which the bitcode writer
|
||||
; will assert on.
|
||||
; RUN: llvm-link -preserve-modules -o %t3.bc -only-needed %t2.bc %t.bc
|
||||
; RUN: llvm-link -preserve-modules -o %t3.bc -only-needed %S/Inputs/only-needed-named-metadata.ll %S/only-needed-named-metadata.ll
|
||||
|
||||
@X = global i32 5
|
||||
@U = global i32 6
|
||||
|
|
Loading…
Reference in New Issue