1 | #include "../all.h" |
2 | |
3 | enum Arm64Reg { |
4 | R0 = RXX + 1, |
5 | R1, R2, R3, R4, R5, R6, R7, |
6 | R8, R9, R10, R11, R12, R13, R14, R15, |
7 | IP0, IP1, R18, R19, R20, R21, R22, R23, |
8 | R24, R25, R26, R27, R28, FP, LR, SP, |
9 | |
10 | V0, V1, V2, V3, V4, V5, V6, V7, |
11 | V8, V9, V10, V11, V12, V13, V14, V15, |
12 | V16, V17, V18, V19, V20, V21, V22, V23, |
13 | V24, V25, V26, V27, V28, V29, V30, /* V31, */ |
14 | |
15 | NFPR = V30 - V0 + 1, |
16 | NGPR = SP - R0 + 1, |
17 | NGPS = R18 - R0 + 1 /* LR */ + 1, |
18 | NFPS = (V7 - V0 + 1) + (V30 - V16 + 1), |
19 | NCLR = (R28 - R19 + 1) + (V15 - V8 + 1), |
20 | }; |
21 | MAKESURE(reg_not_tmp, V30 < (int)Tmp0); |
22 | |
23 | /* targ.c */ |
24 | extern int arm64_rsave[]; |
25 | extern int arm64_rclob[]; |
26 | |
27 | /* abi.c */ |
28 | bits arm64_retregs(Ref, int[2]); |
29 | bits arm64_argregs(Ref, int[2]); |
30 | void arm64_abi(Fn *); |
31 | |
32 | /* isel.c */ |
33 | int arm64_logimm(uint64_t, int); |
34 | void arm64_isel(Fn *); |
35 | |
36 | /* emit.c */ |
37 | void arm64_emitfn(Fn *, FILE *); |
38 | |