diff options
Diffstat (limited to 'src/devices/cpu/apexc/apexcdsm.h')
-rw-r--r-- | src/devices/cpu/apexc/apexcdsm.h | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/src/devices/cpu/apexc/apexcdsm.h b/src/devices/cpu/apexc/apexcdsm.h new file mode 100644 index 00000000000..b310df1f496 --- /dev/null +++ b/src/devices/cpu/apexc/apexcdsm.h @@ -0,0 +1,37 @@ +// license:BSD-3-Clause +// copyright-holders:Raphael Nabet +/* + cpu/apexc/apexcsm.c : APE(X)C CPU disassembler + + By Raphael Nabet + + see cpu/apexc.c for background and tech info +*/ + +#ifndef MAME_CPU_APEXC_APEXCDSM_H +#define MAME_CPU_APEXC_APEXCDSM_H + +#pragma once + +class apexc_disassembler : public util::disasm_interface +{ +public: + apexc_disassembler() = default; + virtual ~apexc_disassembler() = default; + + virtual u32 opcode_alignment() const override; + virtual offs_t disassemble(std::ostream &stream, offs_t pc, const data_buffer &opcodes, const data_buffer ¶ms) override; + +private: + enum format_type {branch, shiftl, shiftr, multiply, store, swap, one_address, two_address}; + + struct instr_desc + { + const char *mnemonic; + format_type format; /* -> X and Y are format */ + }; + + static const instr_desc instructions[16]; +}; + +#endif |