
Always enable opaque pointers in llvm-nm, because the tool doesn't actually care, and this allows us to read both typed pointer and opaque pointer bitcode files in one archive. Previously this depended on the order inside the archive (it would work with an opaque pointer bitcode file first, but fail with a typed pointer bitcode file first). Fixes https://github.com/llvm/llvm-project/issues/55506. Differential Revision: https://reviews.llvm.org/D125751
14 lines
325 B
LLVM
14 lines
325 B
LLVM
; RUN: llvm-as -opaque-pointers=0 < %s > %t.typed.bc
|
|
; RUN: llvm-as -opaque-pointers=1 < %s > %t.opaque.bc
|
|
; RUN: llvm-ar cr %t.a %t.typed.bc %t.opaque.bc
|
|
; RUN: llvm-nm --just-symbol-name %t.a | FileCheck %s
|
|
|
|
; CHECK-LABEL: typed.bc:
|
|
; CHECK: test
|
|
; CHECK-LABEL: opaque.bc:
|
|
; CHECK: test
|
|
|
|
define void @test() {
|
|
ret void
|
|
}
|