File: eh-frame.s

package info (click to toggle)
llvm-toolchain-9 1%3A9.0.1-16
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 882,436 kB
  • sloc: cpp: 4,167,636; ansic: 714,256; asm: 457,610; python: 155,927; objc: 65,094; sh: 42,856; lisp: 26,908; perl: 7,786; pascal: 7,722; makefile: 6,881; ml: 5,581; awk: 3,648; cs: 2,027; xml: 888; javascript: 381; ruby: 156
file content (56 lines) | stat: -rw-r--r-- 2,430 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
// Test the bits of .eh_frame on mips that are already implemented correctly.

// RUN: llvm-mc -filetype=obj %s -o %t.o -triple mips-unknown-linux-gnu
// RUN: llvm-objdump -r -section=.rel.eh_frame %t.o | FileCheck --check-prefix=REL32 %s
// RUN: llvm-dwarfdump -eh-frame %t.o | FileCheck --check-prefix=DWARF32 %s

// RUN: llvm-mc -filetype=obj %s -o %t.o -triple mipsel-unknown-linux-gnu
// RUN: llvm-objdump -r -section=.rel.eh_frame %t.o | FileCheck --check-prefix=REL32 %s
// RUN: llvm-dwarfdump -eh-frame %t.o | FileCheck --check-prefix=DWARF32 %s

// RUN: llvm-mc -filetype=obj %s -o %t.o -triple mips64-unknown-linux-gnu
// RUN: llvm-objdump -r -section=.rela.eh_frame %t.o | FileCheck --check-prefix=REL64 %s
// RUN: llvm-dwarfdump -eh-frame %t.o | FileCheck --check-prefix=DWARF64 %s

// RUN: llvm-mc -filetype=obj %s -o %t.o -triple mips64el-unknown-linux-gnu
// RUN: llvm-objdump -r -section=.rela.eh_frame %t.o | FileCheck --check-prefix=REL64 %s
// RUN: llvm-dwarfdump -eh-frame %t.o | FileCheck --check-prefix=DWARF64 %s

func:
	.cfi_startproc
	.cfi_endproc

// REL32: R_MIPS_32
// REL64: R_MIPS_64/R_MIPS_NONE/R_MIPS_NONE

// DWARF32: 00000000 00000010 ffffffff CIE
// DWARF32:   Version:               1
// DWARF32:   Augmentation:          "zR"
// DWARF32:   Code alignment factor: 1
// DWARF32:   Data alignment factor: -4
// DWARF32:   Return address column: 31
// DWARF32:   Augmentation data:     0B
//                                   ^^ fde pointer encoding: DW_EH_PE_sdata4
// DWARF32:   DW_CFA_def_cfa_register: reg29
//
// DWARF32: 00000014 00000010 00000018 FDE cie=00000018 pc=00000000...00000000
// DWARF32:   DW_CFA_nop:
// DWARF32:   DW_CFA_nop:
// DWARF32:   DW_CFA_nop:

// DWARF64: 00000000 00000010 ffffffff CIE
// DWARF64:   Version:               1
// DWARF64:   Augmentation:          "zR"
// DWARF64:   Code alignment factor: 1
// DWARF64:   Data alignment factor: -8
//                                   ^^ GAS uses -4. Should be ok as long as
//                                      all offsets we need are a multiple of 8.
// DWARF64:   Return address column: 31
// DWARF64:   Augmentation data:     0C
//                                   ^^ fde pointer encoding: DW_EH_PE_sdata8
// DWARF64:   DW_CFA_def_cfa_register: reg29
//
// DWARF64: 00000014 00000018 00000018 FDE cie=00000018 pc=00000000...00000000
// DWARF64:   DW_CFA_nop:
// DWARF64:   DW_CFA_nop:
// DWARF64:   DW_CFA_nop: