brintos

brintos / llvm-project-archived public Read only

0
0
Text · 758 B · ba9d04a Raw
23 lines · plain
1# REQUIRES: x862 3## If for some bizarre reason the input file defines its own ___dso_handle, we4## should raise an error. At least, we've implemented this behavior if the5## conflicting symbol is a global. A local symbol of the same name will still6## take priority in our implementation, unlike in ld64. But that's a pretty7## far-out edge case that should be safe to ignore.8 9# RUN: llvm-mc -filetype=obj -triple=x86_64-apple-darwin %s -o %t.o10# RUN: not %lld -dylib %t.o -o /dev/null 2>&1 | FileCheck %s -DFILE=%t.o11# CHECK:      error: duplicate symbol: ___dso_handle12# CHECK-NEXT: >>> defined in [[FILE]]13# CHECK-NEXT: >>> defined in <internal>14 15.globl _main, ___dso_handle16.text17_main:18  leaq ___dso_handle(%rip), %rdx19  ret20 21___dso_handle:22  .space 123