1 static const ASM_MAPPING _asxxxx_gb_mapping[] = {
4 { "ldahli", "ld a,(hl+)" },
5 { "ldahlsp", "lda hl,%d(sp)" },
6 { "ldaspsp", "lda sp,%d(sp)" },
9 { "enter", "push bc" },
28 { "adjustsp", "lda sp,-%d(sp)" },
32 static const ASM_MAPPING _asxxxx_z80_mapping[] = {
35 { "ldahli", "ld a,(hl+)" },
36 { "ldahlsp", "lda hl,%d(sp)" },
37 { "ldaspsp", "lda sp,%d(sp)" },
40 { "enter", "push bc" },
59 { "adjustsp", "lda sp,-%d(sp)" },
63 static const ASM_MAPPING _rgbds_mapping[] = {
64 { "global", "GLOBAL %s" },
65 { "labeldef", "%s:" },
66 { "tlabeldef", ".l%05d:" },
67 { "tlabel", ".l%05d" },
69 "; Generated using the rgbds tokens.\n"
70 "\t; We have to define these here as sdcc dosnt make them global by default\n"
71 "\tGLOBAL __mulschar\n"
72 "\tGLOBAL __muluchar\n"
73 "\tGLOBAL __mulsint\n"
74 "\tGLOBAL __muluint\n"
75 "\tGLOBAL __divschar\n"
76 "\tGLOBAL __divuchar\n"
77 "\tGLOBAL __divsint\n"
78 "\tGLOBAL __divuint\n"
79 "\tGLOBAL __modschar\n"
80 "\tGLOBAL __moduchar\n"
81 "\tGLOBAL __modsint\n"
85 "; ---------------------------------\n"
87 "; ---------------------------------"
89 { "functionlabeldef", "%s:" },
92 { "area", "SECTION \"%s\",CODE" },
93 { "areacode", "SECTION \"CODE\",CODE" },
94 { "areadata", "SECTION \"DATA\",BSS" },
95 { "ascii", "DB \"%s\"" },
102 { "constbyte", "$%02X" },
103 { "constword", "$%04X" },
104 { "immedword", "$%04X" },
105 { "immedbyte", "$%02X" },
106 { "hashedstr", "%s" },
107 { "lsbimmeds", "%s & $FF" },
108 { "msbimmeds", "%s >> 8" },
109 { "module", "; MODULE %s" },
113 static const ASM_MAPPING _rgbds_gb_mapping[] = {
121 { "adjustsp", "add sp,-%d" },
122 { "enter", "push bc" },
136 { "ldahli", "ld a,[hl+]" },
138 { "ldahlsp", "ld hl,[sp+%d]" },
139 { "ldaspsp", "add sp,%d" },
145 static const ASM_MAPPINGS _rgbds = {
150 const ASM_MAPPINGS _rgbds_gb = {
155 const ASM_MAPPINGS _asxxxx_gb = {
160 const ASM_MAPPINGS _asxxxx_z80 = {