[memprof] Remove an unused using directive (#117004)
[llvm-project.git] / lld / test / ELF / eh-frame-padding-no-rosegment.s
blob67be65895ef4d90a35cb653d3e1ad29b62422756
1 // REQUIRES: x86
3 .cfi_startproc
4 .cfi_personality 0x1b, bar
5 .cfi_endproc
7 .global bar
8 .hidden bar
9 bar:
10 ret
12 // RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
14 // Check the size of the CIE (0x18 + 4) and FDE (0x10 + 4)
15 // RUN: llvm-readobj -S --section-data %t.o | FileCheck --check-prefix=OBJ %s
17 // OBJ: Name: .eh_frame
18 // OBJ-NEXT: Type:
19 // OBJ-NEXT: Flags [
20 // OBJ-NEXT: SHF_ALLOC
21 // OBJ-NEXT: ]
22 // OBJ-NEXT: Address:
23 // OBJ-NEXT: Offset:
24 // OBJ-NEXT: Size:
25 // OBJ-NEXT: Link:
26 // OBJ-NEXT: Info:
27 // OBJ-NEXT: AddressAlignment:
28 // OBJ-NEXT: EntrySize:
29 // OBJ-NEXT: SectionData (
30 // OBJ-NEXT: 0000: 18000000 00000000 017A5052 00017810
31 // OBJ-NEXT: 0010: 061B0000 00001B0C 07089001 10000000
32 // OBJ-NEXT: 0020: 20000000 00000000 00000000 00000000
33 // OBJ-NEXT: )
35 // RUN: ld.lld --hash-style=sysv %t.o --no-rosegment -o %t -shared
37 // Check that .eh_frame is in the same segment as .text
38 // RUN: llvm-readelf -l %t | FileCheck --check-prefix=PHDR %s
40 // PHDR: Segment Sections
41 // PHDR: .eh_frame {{.*}}.text
43 // Check that the CIE and FDE are padded with 0x00 and not 0xCC when the
44 // .eh_frame section is placed in the executable segment
45 // RUN: llvm-readobj -S --section-data %t | FileCheck %s
47 // CHECK: Name: .eh_frame
48 // CHECK-NEXT: Type:
49 // CHECK-NEXT: Flags
50 // CHECK-NEXT: SHF_ALLOC
51 // CHECK-NEXT: ]
52 // CHECK-NEXT: Address:
53 // CHECK-NEXT: Offset:
54 // CHECK-NEXT: Size:
55 // CHECK-NEXT: Link:
56 // CHECK-NEXT: Info:
57 // CHECK-NEXT: AddressAlignment:
58 // CHECK-NEXT: EntrySize:
59 // CHECK-NEXT: SectionData (
60 // CHECK-NEXT: 0000: 18000000 00000000 017A5052 00017810
61 // CHECK-NEXT: 0010: 061B2200 00001B0C 07089001 10000000
62 // CHECK-NEXT: 0020: 20000000 10000000 00000000 00000000
63 // CHECK-NEXT: 0030: 00000000
64 // CHECK-NEXT: )