X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=cpu%2Fsh2%2Fcompiler.c;h=e9838978ee6cf2833b81d56c986d513f6932bd60;hb=2dbc96b1c783a2cb147321f6131d67691d36e592;hp=d3eb387825e92fe4cd45fb2976b2b132b078b032;hpb=f3fe3e5ba2e5966bb08f51c9e78716ee07651058;p=picodrive.git diff --git a/cpu/sh2/compiler.c b/cpu/sh2/compiler.c index d3eb387..e983897 100644 --- a/cpu/sh2/compiler.c +++ b/cpu/sh2/compiler.c @@ -270,6 +270,8 @@ typedef struct { #ifdef __arm__ #include "../drc/emit_arm.c" +#ifndef __MACH__ + static const int reg_map_g2h[] = { 4, 5, 6, 7, 8, -1, -1, -1, @@ -279,6 +281,20 @@ static const int reg_map_g2h[] = { -1, -1, -1, -1, // SHR_GBR, SHR_VBR, SHR_MACH, SHR_MACL, }; +#else + +// no r9.. +static const int reg_map_g2h[] = { + 4, 5, 6, 7, + -1, -1, -1, -1, + -1, -1, -1, -1, + -1, -1, -1, 8, // r12 .. sp + -1, -1, -1, 10, // SHR_PC, SHR_PPC, SHR_PR, SHR_SR, + -1, -1, -1, -1, // SHR_GBR, SHR_VBR, SHR_MACH, SHR_MACL, +}; + +#endif + static temp_reg_t reg_temp[] = { { 0, }, { 1, },