Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(42)

Side by Side Diff: src/IceInstARM32.def

Issue 1159013002: Subzero ARM: addProlog/addEpilogue -- share some code with x86. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: typo Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/IceInstARM32.cpp ('k') | src/IceTargetLowering.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/IceInstARM32.def - X-Macros for ARM32 insts --*- C++ -*-===// 1 //===- subzero/src/IceInstARM32.def - X-Macros for ARM32 insts --*- C++ -*-===//
2 // 2 //
3 // The Subzero Code Generator 3 // The Subzero Code Generator
4 // 4 //
5 // This file is distributed under the University of Illinois Open Source 5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details. 6 // License. See LICENSE.TXT for details.
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 // 9 //
10 // This file defines properties of ARM32 instructions in the form of x-macros. 10 // This file defines properties of ARM32 instructions in the form of x-macros.
11 // 11 //
12 //===----------------------------------------------------------------------===// 12 //===----------------------------------------------------------------------===//
13 13
14 #ifndef SUBZERO_SRC_ICEINSTARM32_DEF 14 #ifndef SUBZERO_SRC_ICEINSTARM32_DEF
15 #define SUBZERO_SRC_ICEINSTARM32_DEF 15 #define SUBZERO_SRC_ICEINSTARM32_DEF
16 16
17 // NOTE: PC and SP are not considered isInt, to avoid register allocating. 17 // NOTE: PC and SP are not considered isInt, to avoid register allocating.
18 //
18 // For the NaCl sandbox we also need to r9 for TLS, so just reserve always. 19 // For the NaCl sandbox we also need to r9 for TLS, so just reserve always.
19 // TODO(jvoung): Allow r9 to be isInt when sandboxing is turned off 20 // TODO(jvoung): Allow r9 to be isInt when sandboxing is turned off
20 // (native mode). 21 // (native mode).
22 //
23 // LR is not considered isInt to avoid being allocated as a register.
24 // It is technically preserved, but save/restore is handled separately,
25 // based on whether or not the function MaybeLeafFunc.
21 #define REGARM32_GPR_TABLE \ 26 #define REGARM32_GPR_TABLE \
22 /* val, encode, name, scratch, preserved, stackptr, frameptr, isInt, isFP */ \ 27 /* val, encode, name, scratch, preserved, stackptr, frameptr, isInt, isFP */ \
23 X(Reg_r0, = 0, "r0", 1, 0, 0, 0, 1, 0) \ 28 X(Reg_r0, = 0, "r0", 1, 0, 0, 0, 1, 0) \
24 X(Reg_r1, = Reg_r0 + 1, "r1", 1, 0, 0, 0, 1, 0) \ 29 X(Reg_r1, = Reg_r0 + 1, "r1", 1, 0, 0, 0, 1, 0) \
25 X(Reg_r2, = Reg_r0 + 2, "r2", 1, 0, 0, 0, 1, 0) \ 30 X(Reg_r2, = Reg_r0 + 2, "r2", 1, 0, 0, 0, 1, 0) \
26 X(Reg_r3, = Reg_r0 + 3, "r3", 1, 0, 0, 0, 1, 0) \ 31 X(Reg_r3, = Reg_r0 + 3, "r3", 1, 0, 0, 0, 1, 0) \
27 X(Reg_r4, = Reg_r0 + 4, "r4", 0, 1, 0, 0, 1, 0) \ 32 X(Reg_r4, = Reg_r0 + 4, "r4", 0, 1, 0, 0, 1, 0) \
28 X(Reg_r5, = Reg_r0 + 5, "r5", 0, 1, 0, 0, 1, 0) \ 33 X(Reg_r5, = Reg_r0 + 5, "r5", 0, 1, 0, 0, 1, 0) \
29 X(Reg_r6, = Reg_r0 + 6, "r6", 0, 1, 0, 0, 1, 0) \ 34 X(Reg_r6, = Reg_r0 + 6, "r6", 0, 1, 0, 0, 1, 0) \
30 X(Reg_r7, = Reg_r0 + 7, "r7", 0, 1, 0, 0, 1, 0) \ 35 X(Reg_r7, = Reg_r0 + 7, "r7", 0, 1, 0, 0, 1, 0) \
31 X(Reg_r8, = Reg_r0 + 8, "r8", 0, 1, 0, 0, 1, 0) \ 36 X(Reg_r8, = Reg_r0 + 8, "r8", 0, 1, 0, 0, 1, 0) \
32 X(Reg_r9, = Reg_r0 + 9, "r9", 0, 1, 0, 0, 0, 0) \ 37 X(Reg_r9, = Reg_r0 + 9, "r9", 0, 1, 0, 0, 0, 0) \
33 X(Reg_r10, = Reg_r0 + 10, "r10", 0, 1, 0, 0, 1, 0) \ 38 X(Reg_r10, = Reg_r0 + 10, "r10", 0, 1, 0, 0, 1, 0) \
34 X(Reg_fp, = Reg_r0 + 11, "fp", 0, 1, 0, 1, 1, 0) \ 39 X(Reg_fp, = Reg_r0 + 11, "fp", 0, 1, 0, 1, 1, 0) \
35 X(Reg_ip, = Reg_r0 + 12, "ip", 1, 0, 0, 0, 1, 0) \ 40 X(Reg_ip, = Reg_r0 + 12, "ip", 1, 0, 0, 0, 1, 0) \
36 X(Reg_sp, = Reg_r0 + 13, "sp", 0, 1, 1, 0, 0, 0) \ 41 X(Reg_sp, = Reg_r0 + 13, "sp", 0, 0, 1, 0, 0, 0) \
37 X(Reg_lr, = Reg_r0 + 14, "lr", 0, 1, 0, 0, 1, 0) \ 42 X(Reg_lr, = Reg_r0 + 14, "lr", 0, 0, 0, 0, 0, 0) \
38 X(Reg_pc, = Reg_r0 + 15, "pc", 0, 1, 0, 0, 0, 0) \ 43 X(Reg_pc, = Reg_r0 + 15, "pc", 0, 0, 0, 0, 0, 0) \
39 //#define X(val, encode, name, scratch, preserved, stackptr, frameptr, 44 //#define X(val, encode, name, scratch, preserved, stackptr, frameptr,
40 // isInt, isFP) 45 // isInt, isFP)
41 46
42 // TODO(jvoung): List FP registers and know S0 == D0 == Q0, etc. 47 // TODO(jvoung): List FP registers and know S0 == D0 == Q0, etc.
43 // Be able to grab even registers, and the corresponding odd register 48 // Be able to grab even registers, and the corresponding odd register
44 // for each even register. 49 // for each even register.
45 50
46 // We also provide a combined table, so that there is a namespace where 51 // We also provide a combined table, so that there is a namespace where
47 // all of the registers are considered and have distinct numberings. 52 // all of the registers are considered and have distinct numberings.
48 // This is in contrast to the above, where the "encode" is based on how 53 // This is in contrast to the above, where the "encode" is based on how
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 X(LS, 9, HI, "ls") /* unsigned lower or same */ \ 113 X(LS, 9, HI, "ls") /* unsigned lower or same */ \
109 X(GE, 10, LT, "ge") /* signed greater than or equal */ \ 114 X(GE, 10, LT, "ge") /* signed greater than or equal */ \
110 X(LT, 11, GE, "lt") /* signed less than */ \ 115 X(LT, 11, GE, "lt") /* signed less than */ \
111 X(GT, 12, LE, "gt") /* signed greater than */ \ 116 X(GT, 12, LE, "gt") /* signed greater than */ \
112 X(LE, 13, GT, "le") /* signed less than or equal */ \ 117 X(LE, 13, GT, "le") /* signed less than or equal */ \
113 X(AL, 14, kNone, "") /* always (unconditional) */ \ 118 X(AL, 14, kNone, "") /* always (unconditional) */ \
114 X(kNone, 15, kNone, "??") /* special condition / none */ \ 119 X(kNone, 15, kNone, "??") /* special condition / none */ \
115 //#define(tag, encode, opp, emit) 120 //#define(tag, encode, opp, emit)
116 121
117 #endif // SUBZERO_SRC_ICEINSTARM32_DEF 122 #endif // SUBZERO_SRC_ICEINSTARM32_DEF
OLDNEW
« no previous file with comments | « src/IceInstARM32.cpp ('k') | src/IceTargetLowering.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698