1// RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu %s -o - | llvm-readobj --symbols - | FileCheck %s 2 3// Test which symbols should be in the symbol table 4 5.Lsym2: 6.Lsym3: 7.Lsym4 = .Lsym2 - .Lsym3 8 .long .Lsym4 9 10 .type .Lsym5,@object 11 .type sym6,@object 12 .long sym6 13 14 .section .rodata.str1.1,"aMS",@progbits,1 15.Lsym7: 16.Lsym8: 17 18 .text 19 movsd .Lsym8(%rip), %xmm1 20 21.hidden hidden 22 23test2_a = undef 24test2_b = undef + 1 25 26// CHECK: Symbols [ 27// CHECK-NEXT: Symbol { 28// CHECK-NEXT: Name: (0) 29// CHECK-NEXT: Value: 0x0 30// CHECK-NEXT: Size: 0 31// CHECK-NEXT: Binding: Local 32// CHECK-NEXT: Type: None 33// CHECK-NEXT: Other: 0 34// CHECK-NEXT: Section: Undefined 35// CHECK-NEXT: } 36// CHECK-NEXT: Symbol { 37// CHECK-NEXT: Name: .Lsym8 38// CHECK-NEXT: Value: 0x0 39// CHECK-NEXT: Size: 0 40// CHECK-NEXT: Binding: Local 41// CHECK-NEXT: Type: None 42// CHECK-NEXT: Other: 0 43// CHECK-NEXT: Section: .rodata.str1.1 44// CHECK-NEXT: } 45// CHECK-NEXT: Symbol { 46// CHECK-NEXT: Name: hidden 47// CHECK-NEXT: Value: 0x0 48// CHECK-NEXT: Size: 0 49// CHECK-NEXT: Binding: Global 50// CHECK-NEXT: Type: None 51// CHECK-NEXT: Other [ 52// CHECK-NEXT: STV_HIDDEN 53// CHECK-NEXT: ] 54// CHECK-NEXT: Section: Undefined 55// CHECK-NEXT: } 56// CHECK-NEXT: Symbol { 57// CHECK-NEXT: Name: sym6 58// CHECK-NEXT: Value: 0x0 59// CHECK-NEXT: Size: 0 60// CHECK-NEXT: Binding: Global 61// CHECK-NEXT: Type: Object 62// CHECK-NEXT: Other: 0 63// CHECK-NEXT: Section: Undefined 64// CHECK-NEXT: } 65// CHECK-NEXT: Symbol { 66// CHECK-NEXT: Name: undef 67// CHECK-NEXT: Value: 0x0 68// CHECK-NEXT: Size: 0 69// CHECK-NEXT: Binding: Global 70// CHECK-NEXT: Type: None 71// CHECK-NEXT: Other: 0 72// CHECK-NEXT: Section: Undefined 73// CHECK-NEXT: } 74// CHECK-NEXT: ] 75