LLVM 20.0.0git
ARMEHABI.h
Go to the documentation of this file.
1//===--- ARMEHABI.h - ARM Exception Handling ABI ----------------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// This file defines the constants for the ARM unwind opcodes and exception
10// handling table entry kinds.
11//
12// The enumerations and constants in this file reflect the ARM EHABI
13// Specification as published by ARM.
14//
15// Exception Handling ABI for the ARM Architecture r2.09 - November 30, 2012
16//
17// http://infocenter.arm.com/help/topic/com.arm.doc.ihi0038a/IHI0038A_ehabi.pdf
18//
19//===----------------------------------------------------------------------===//
20
21#ifndef LLVM_SUPPORT_ARMEHABI_H
22#define LLVM_SUPPORT_ARMEHABI_H
23
24namespace llvm {
25namespace ARM {
26namespace EHABI {
27 /// ARM exception handling table entry kinds
30 EHT_COMPACT = 0x80
31 };
32
33 enum {
34 /// Special entry for the function never unwind
36 };
37
38 /// ARM-defined frame unwinding opcodes
40 // Format: 00xxxxxx
41 // Purpose: vsp = vsp + ((x << 2) + 4)
43
44 // Format: 01xxxxxx
45 // Purpose: vsp = vsp - ((x << 2) + 4)
47
48 // Format: 10000000 00000000
49 // Purpose: refuse to unwind
51
52 // Format: 1000xxxx xxxxxxxx
53 // Purpose: pop r[15:12], r[11:4]
54 // Constraint: x != 0
56
57 // Format: 1001xxxx
58 // Purpose: vsp = r[x]
59 // Constraint: x != 13 && x != 15
61
62 // Format: 10100xxx
63 // Purpose: pop r[(4+x):4]
65
66 // Format: 10101xxx
67 // Purpose: pop r14, r[(4+x):4]
69
70 // Format: 10110000
71 // Purpose: finish
73
74 // Format: 10110100
75 // Purpose: Pop Return Address Authetication Code
77
78 // Format: 10110001 0000xxxx
79 // Purpose: pop r[3:0]
80 // Constraint: x != 0
82
83 // Format: 10110010 x(uleb128)
84 // Purpose: vsp = vsp + ((x << 2) + 0x204)
86
87 // Format: 10110011 xxxxyyyy
88 // Purpose: pop d[(x+y):x]
90
91 // Format: 10111xxx
92 // Purpose: pop d[(8+x):8]
94
95 // Format: 11000xxx
96 // Purpose: pop wR[(10+x):10]
98
99 // Format: 11000110 xxxxyyyy
100 // Purpose: pop wR[(x+y):x]
102
103 // Format: 11000111 0000xxxx
104 // Purpose: pop wCGR[3:0]
105 // Constraint: x != 0
107
108 // Format: 11001000 xxxxyyyy
109 // Purpose: pop d[(16+x+y):(16+x)]
111
112 // Format: 11001001 xxxxyyyy
113 // Purpose: pop d[(x+y):x]
115
116 // Format: 11010xxx
117 // Purpose: pop d[(8+x):8]
119 };
120
121 /// ARM-defined Personality Routine Index
123 // To make the exception handling table become more compact, ARM defined
124 // several personality routines in EHABI. There are 3 different
125 // personality routines in ARM EHABI currently. It is possible to have 16
126 // pre-defined personality routines at most.
130
132 };
133}
134}
135}
136
137#endif
UnwindOpcodes
ARM-defined frame unwinding opcodes.
Definition: ARMEHABI.h:39
@ UNWIND_OPCODE_POP_REG_RANGE_R4
Definition: ARMEHABI.h:64
@ UNWIND_OPCODE_FINISH
Definition: ARMEHABI.h:72
@ UNWIND_OPCODE_REFUSE
Definition: ARMEHABI.h:50
@ UNWIND_OPCODE_POP_VFP_REG_RANGE_FSTMFDX_D8
Definition: ARMEHABI.h:93
@ UNWIND_OPCODE_POP_WIRELESS_MMX_REG_MASK
Definition: ARMEHABI.h:106
@ UNWIND_OPCODE_POP_WIRELESS_MMX_REG_RANGE
Definition: ARMEHABI.h:101
@ UNWIND_OPCODE_POP_VFP_REG_RANGE_FSTMFDD_D8
Definition: ARMEHABI.h:118
@ UNWIND_OPCODE_DEC_VSP
Definition: ARMEHABI.h:46
@ UNWIND_OPCODE_POP_WIRELESS_MMX_REG_RANGE_WR10
Definition: ARMEHABI.h:97
@ UNWIND_OPCODE_POP_VFP_REG_RANGE_FSTMFDD_D16
Definition: ARMEHABI.h:110
@ UNWIND_OPCODE_POP_REG_MASK
Definition: ARMEHABI.h:81
@ UNWIND_OPCODE_INC_VSP
Definition: ARMEHABI.h:42
@ UNWIND_OPCODE_INC_VSP_ULEB128
Definition: ARMEHABI.h:85
@ UNWIND_OPCODE_POP_VFP_REG_RANGE_FSTMFDX
Definition: ARMEHABI.h:89
@ UNWIND_OPCODE_POP_REG_RANGE_R4_R14
Definition: ARMEHABI.h:68
@ UNWIND_OPCODE_POP_RA_AUTH_CODE
Definition: ARMEHABI.h:76
@ UNWIND_OPCODE_POP_VFP_REG_RANGE_FSTMFDD
Definition: ARMEHABI.h:114
@ UNWIND_OPCODE_POP_REG_MASK_R4
Definition: ARMEHABI.h:55
@ UNWIND_OPCODE_SET_VSP
Definition: ARMEHABI.h:60
PersonalityRoutineIndex
ARM-defined Personality Routine Index.
Definition: ARMEHABI.h:122
@ EXIDX_CANTUNWIND
Special entry for the function never unwind.
Definition: ARMEHABI.h:35
EHTEntryKind
ARM exception handling table entry kinds.
Definition: ARMEHABI.h:28
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18