debug_frame.s revision e3a0e987f3d4f07512cdb64b9034369f966cb448
1// RUN: llvm-mc -triple i386-apple-darwin %s -filetype=obj -o - | macho-dump | FileCheck %s
2
3// Check that we don't produce a relocation for the CIE pointer and therefore
4// we have only one relocation in __debug_frame.
5
6	.section	__TEXT,__text,regular,pure_instructions
7	.globl	_f
8	.align	4, 0x90
9_f:                                     ## @f
10Ltmp0:
11	.cfi_startproc
12## BB#0:                                ## %entry
13	movl	$42, %eax
14	ret
15Ltmp1:
16	.cfi_endproc
17Leh_func_end0:
18
19	.cfi_sections .debug_frame
20Ltext_end:
21
22// CHECK:       (('section_name', '__debug_frame\x00\x00\x00')
23// CHECK-NEXT:   ('segment_name', '__DWARF\x00\x00\x00\x00\x00\x00\x00\x00\x00')
24// CHECK-NEXT:   ('address', 8)
25// CHECK-NEXT:   ('size', 36)
26// CHECK-NEXT:   ('offset', 332)
27// CHECK-NEXT:   ('alignment', 2)
28// CHECK-NEXT:   ('reloc_offset', 368)
29// CHECK-NEXT:   ('num_reloc', 1)
30// CHECK-NEXT:   ('flags', 0x2000000)
31// CHECK-NEXT:   ('reserved1', 0)
32// CHECK-NEXT:   ('reserved2', 0)
33// CHECK-NEXT:  ),
34// CHECK-NEXT: ('_relocations', [
35// CHECK-NEXT:   # Relocation 0
36// CHECK-NEXT:   (('word-0', 0x1c),
37// CHECK-NEXT:    ('word-1', 0x4000001)),
38// CHECK-NEXT: ])
39