2016-04-24 12:29:59 +08:00
|
|
|
# REQUIRES: x86
|
|
|
|
# RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
|
|
|
|
# RUN: ld.lld %t.o -o %t -pie
|
|
|
|
# RUN: llvm-readobj -dyn-symbols %t | FileCheck %s
|
|
|
|
|
|
|
|
# CHECK: DynamicSymbols [
|
|
|
|
# CHECK-NEXT: Symbol {
|
2016-11-02 05:26:28 +08:00
|
|
|
# CHECK-NEXT: Name: @
|
2016-04-24 12:29:59 +08:00
|
|
|
# CHECK-NEXT: Value: 0x0
|
|
|
|
# CHECK-NEXT: Size: 0
|
|
|
|
# CHECK-NEXT: Binding: Local (0x0)
|
|
|
|
# CHECK-NEXT: Type: None (0x0)
|
|
|
|
# CHECK-NEXT: Other: 0
|
|
|
|
# CHECK-NEXT: Section: Undefined (0x0)
|
|
|
|
# CHECK-NEXT: }
|
2017-09-16 02:05:02 +08:00
|
|
|
# CHECK-NEXT: Symbol {
|
|
|
|
# CHECK-NEXT: Name: foo@
|
|
|
|
# CHECK-NEXT: Value: 0x0
|
|
|
|
# CHECK-NEXT: Size: 0
|
|
|
|
# CHECK-NEXT: Binding: Weak
|
|
|
|
# CHECK-NEXT: Type: None
|
|
|
|
# CHECK-NEXT: Other: 0
|
|
|
|
# CHECK-NEXT: Section: Undefined
|
|
|
|
# CHECK-NEXT: }
|
2016-04-24 12:29:59 +08:00
|
|
|
# CHECK-NEXT: ]
|
|
|
|
|
|
|
|
.weak foo
|
|
|
|
|
|
|
|
.globl _start
|
|
|
|
_start:
|
2017-11-24 14:42:32 +08:00
|
|
|
|
|
|
|
.data
|
|
|
|
.dc.a foo
|