Skip to content

Commit 8b4c098

Browse files
committed
Add Z80 stuff to readme; remove redundant .gbc directive
1 parent 6f877d4 commit 8b4c098

File tree

3 files changed

+12
-7
lines changed

3 files changed

+12
-7
lines changed

Parser/DirectivesParser.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -458,9 +458,6 @@ std::unique_ptr<CAssemblerCommand> parseDirectiveZ80Arch(Parser& parser, int fla
458458
case DIRECTIVE_Z80_GB:
459459
Z80.SetVersion(Z80ArchType::Gameboy);
460460
return std::make_unique<ArchitectureCommand>(L".gb", L"");
461-
case DIRECTIVE_Z80_GBC:
462-
Z80.SetVersion(Z80ArchType::Gameboy);
463-
return std::make_unique<ArchitectureCommand>(L".gbc", L"");
464461
case DIRECTIVE_Z80_EREADER:
465462
Z80.SetVersion(Z80ArchType::Ereader);
466463
return std::make_unique<ArchitectureCommand>(L".ereader", L"");
@@ -802,7 +799,6 @@ const DirectiveMap directives = {
802799

803800
{ L".z80", { &parseDirectiveZ80Arch, DIRECTIVE_Z80_Z80 } },
804801
{ L".gb", { &parseDirectiveZ80Arch, DIRECTIVE_Z80_GB } },
805-
{ L".gbc", { &parseDirectiveZ80Arch, DIRECTIVE_Z80_GBC } },
806802
{ L".ereader", { &parseDirectiveZ80Arch, DIRECTIVE_Z80_EREADER } },
807803

808804
{ L".area", { &parseDirectiveArea, 0 } },

Parser/DirectivesParser.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,7 @@ using DirectiveMap = std::unordered_multimap<std::wstring, const DirectiveEntry>
7171
// Z80 directive flags
7272
#define DIRECTIVE_Z80_Z80 0x00000001
7373
#define DIRECTIVE_Z80_GB 0x00000002
74-
#define DIRECTIVE_Z80_GBC 0x00000003
75-
#define DIRECTIVE_Z80_EREADER 0x00000004
74+
#define DIRECTIVE_Z80_EREADER 0x00000003
7675

7776
// Area directive flags
7877
#define DIRECTIVE_AREA_SHARED 0x00000001

Readme.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,13 @@ Please refer to the CMake documentation for further information.
105105

106106
# 3. Overview
107107

108-
The assembler includes full support for the MIPS R3000, MIPS R4000, Allegrex and RSP instruction sets, partial support for the EmotionEngine instruction set, as well as complete support for the ARM7 and ARM9 instruction sets, both THUMB and ARM mode. Among the other features of the assembler are:
108+
The assembler supports the following architectures:
109+
110+
* The full MIPS R3000, MIPS R4000, Allegrex and RSP instruction sets, with partial support for the EmotionEngine instruction set.
111+
* The full ARM7 and ARM9 instruction sets, both THUMB and ARM mode.
112+
* The full Z80 and LR35902 instruction sets, as well as Nintendo e-Reader instructions.
113+
114+
Among the other features of the assembler are:
109115

110116
* a full fledged C-like expression parser. It should behave exactly like in any C/C++ code, including all the weirdness. All immediate values can be specified by an expression, though some directives can't use variable addresses including labels
111117
* you can open several files in a row, but only one output file can be open at any time. You can specify its address in memory to allow overlay support. Any file can cross-reference any other included file
@@ -458,8 +464,11 @@ These directives can be used to set the architecture that the following assembly
458464
| `.gba` | Game Boy Advance | ARM7 | Defaults to THUMB mode |
459465
| `.nds` | Nintendo DS | ARM9 | Defaults to ARM mode |
460466
| `.3ds` | Nintendo 3DS | ARM11 | Defaults to ARM mode, incomplete |
467+
| `.gb` | Game Boy (Color) | LR35902 | - |
468+
| `.ereader` | Nintendo e-Reader | e-Reader Z80 | - |
461469
| `.arm.big` | - | ARM | Output in big endian |
462470
| `.arm.little` | - | ARM | Output in little endian |
471+
| `.z80` | - | Z80 | - |
463472

464473
### Open a generic file
465474

@@ -1115,6 +1124,7 @@ will align the memory address to a multiple of 4, then create a label named `Mai
11151124
## 7.1 Change log
11161125

11171126
* Version 0.11
1127+
* added support for Z80, LR35902 (Game Boy) and Nintendo e-Reader Z80
11181128
* new `.aligna` directive for absolute address alignment
11191129
* new expression functions: `org(label)`, `orga(label)`, `headersize(label)`
11201130
* new expression functions: `min` and `max`

0 commit comments

Comments
 (0)