1@ RUN: llvm-mc %s -triple=armv7-unknown-linux-gnueabi -filetype=obj -o - \ 2@ RUN: | llvm-readobj -s | FileCheck %s 3 4@ Test that the ARM_EXIDX sections point (Link) to the corresponding text 5@ sections. 6 7@ FIXME: The section numbers are not important. If llvm-readobj printed the 8@ name first we could use a FileCheck variable. 9 10@ CHECK: Section { 11@ CHECK: Index: 4 12@ CHECK-NEXT: Name: .text 13@ CHECK-NEXT: Type: SHT_PROGBITS 14@ CHECK-NEXT: Flags [ 15@ CHECK-NEXT: SHF_ALLOC 16@ CHECK-NEXT: SHF_EXECINSTR 17@ CHECK-NEXT: SHF_GROUP 18@ CHECK-NEXT: ] 19@ CHECK-NEXT: Address: 0x0 20@ CHECK-NEXT: Offset: 21@ CHECK-NEXT: Size: 4 22@ CHECK-NEXT: Link: 0 23@ CHECK-NEXT: Info: 0 24@ CHECK-NEXT: AddressAlignment: 1 25@ CHECK-NEXT: EntrySize: 0 26@ CHECK-NEXT: } 27@ CHECK-NEXT: Section { 28@ CHECK-NEXT: Index: 5 29@ CHECK-NEXT: Name: .ARM.exidx 30@ CHECK-NEXT: Type: SHT_ARM_EXIDX 31@ CHECK-NEXT: Flags [ 32@ CHECK-NEXT: SHF_ALLOC 33@ CHECK-NEXT: SHF_GROUP 34@ CHECK-NEXT: SHF_LINK_ORDER 35@ CHECK-NEXT: ] 36@ CHECK-NEXT: Address: 0x0 37@ CHECK-NEXT: Offset: 38@ CHECK-NEXT: Size: 8 39@ CHECK-NEXT: Link: 4 40@ CHECK-NEXT: Info: 0 41@ CHECK-NEXT: AddressAlignment: 4 42@ CHECK-NEXT: EntrySize: 0 43@ CHECK-NEXT: } 44 45@ CHECK: Section { 46@ CHECK: Index: 8 47@ CHECK-NEXT: Name: .text 48@ CHECK-NEXT: Type: SHT_PROGBITS 49@ CHECK-NEXT: Flags [ 50@ CHECK-NEXT: SHF_ALLOC 51@ CHECK-NEXT: SHF_EXECINSTR 52@ CHECK-NEXT: SHF_GROUP 53@ CHECK-NEXT: ] 54@ CHECK-NEXT: Address: 0x0 55@ CHECK-NEXT: Offset: 56@ CHECK-NEXT: Size: 4 57@ CHECK-NEXT: Link: 0 58@ CHECK-NEXT: Info: 0 59@ CHECK-NEXT: AddressAlignment: 1 60@ CHECK-NEXT: EntrySize: 0 61@ CHECK-NEXT: } 62@ CHECK-NEXT: Section { 63@ CHECK-NEXT: Index: 9 64@ CHECK-NEXT: Name: .ARM.exidx 65@ CHECK-NEXT: Type: SHT_ARM_EXIDX 66@ CHECK-NEXT: Flags [ 67@ CHECK-NEXT: SHF_ALLOC 68@ CHECK-NEXT: SHF_GROUP 69@ CHECK-NEXT: SHF_LINK_ORDER 70@ CHECK-NEXT: ] 71@ CHECK-NEXT: Address: 0x0 72@ CHECK-NEXT: Offset: 73@ CHECK-NEXT: Size: 8 74@ CHECK-NEXT: Link: 8 75@ CHECK-NEXT: Info: 0 76@ CHECK-NEXT: AddressAlignment: 4 77@ CHECK-NEXT: EntrySize: 0 78@ CHECK-NEXT: } 79 80 .section .text,"axG",%progbits,f,comdat 81f: 82 .fnstart 83 mov pc, lr 84 .fnend 85 86 .section .text,"axG",%progbits,g,comdat 87g: 88 .fnstart 89 mov pc, lr 90 .fnend 91