From 0ff65c514c93472bf77edb987c9c97464ff7238f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felipe=20Corr=C3=AAa=20da=20Silva=20Sanches?= Date: Tue, 2 Jan 2024 00:22:13 +0000 Subject: [PATCH] fix dasm of control registers --- src/devices/cpu/tlcs900/dasm900.cpp | 12 ++++++------ src/devices/cpu/tlcs900/dasm900.h | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/devices/cpu/tlcs900/dasm900.cpp b/src/devices/cpu/tlcs900/dasm900.cpp index ed839ded2edb1..f8c4435f9ac7c 100644 --- a/src/devices/cpu/tlcs900/dasm900.cpp +++ b/src/devices/cpu/tlcs900/dasm900.cpp @@ -1519,7 +1519,7 @@ u32 tlcs900_disassembler::opcode_alignment() const return 1; } -void tlcs900_disassembler::decode_control_register_8(std::ostream &stream, uint32_t imm){ +void tlcs900_disassembler::decode_control_register_8(std::ostream &stream, uint8_t imm){ switch( imm ) { case 0x22: util::stream_format(stream, " DMAM0"); break; @@ -1533,7 +1533,7 @@ void tlcs900_disassembler::decode_control_register_8(std::ostream &stream, uint3 } -void tmp94c241_disassembler::decode_control_register_8(std::ostream &stream, uint32_t imm){ +void tmp94c241_disassembler::decode_control_register_8(std::ostream &stream, uint8_t imm){ switch( imm ) { case 0x42: util::stream_format(stream, " DMAM0"); break; @@ -1551,7 +1551,7 @@ void tmp94c241_disassembler::decode_control_register_8(std::ostream &stream, uin } -void tlcs900_disassembler::decode_control_register_16(std::ostream &stream, uint32_t imm){ +void tlcs900_disassembler::decode_control_register_16(std::ostream &stream, uint8_t imm){ switch( imm ) { case 0x20: util::stream_format(stream, " DMAC0"); break; @@ -1566,7 +1566,7 @@ void tlcs900_disassembler::decode_control_register_16(std::ostream &stream, uint } -void tmp94c241_disassembler::decode_control_register_16(std::ostream &stream, uint32_t imm){ +void tmp94c241_disassembler::decode_control_register_16(std::ostream &stream, uint8_t imm){ switch( imm ) { case 0x40: util::stream_format(stream, " DMAC0"); break; @@ -1584,7 +1584,7 @@ void tmp94c241_disassembler::decode_control_register_16(std::ostream &stream, ui } -void tlcs900_disassembler::decode_control_register_32(std::ostream &stream, uint32_t imm){ +void tlcs900_disassembler::decode_control_register_32(std::ostream &stream, uint8_t imm){ switch( imm ) { case 0x00: util::stream_format(stream, " DMAS0"); break; @@ -1602,7 +1602,7 @@ void tlcs900_disassembler::decode_control_register_32(std::ostream &stream, uint } -void tmp94c241_disassembler::decode_control_register_32(std::ostream &stream, uint32_t imm){ +void tmp94c241_disassembler::decode_control_register_32(std::ostream &stream, uint8_t imm){ switch( imm ) { case 0x00: util::stream_format(stream, " DMAS0"); break; diff --git a/src/devices/cpu/tlcs900/dasm900.h b/src/devices/cpu/tlcs900/dasm900.h index 4ec517de6bf30..a84363fc91f3b 100644 --- a/src/devices/cpu/tlcs900/dasm900.h +++ b/src/devices/cpu/tlcs900/dasm900.h @@ -15,9 +15,9 @@ class tlcs900_disassembler : public util::disasm_interface { protected: tlcs900_disassembler(uint16_t num_sfr, const char *const sfr_names[]); - void decode_control_register_8(std::ostream &stream, uint32_t imm); - void decode_control_register_16(std::ostream &stream, uint32_t imm); - void decode_control_register_32(std::ostream &stream, uint32_t imm); + virtual void decode_control_register_8(std::ostream &stream, uint8_t imm); + virtual void decode_control_register_16(std::ostream &stream, uint8_t imm); + virtual void decode_control_register_32(std::ostream &stream, uint8_t imm); public: virtual ~tlcs900_disassembler() = default; @@ -120,9 +120,9 @@ class tmp94c241_disassembler : public tlcs900_disassembler { public: tmp94c241_disassembler(); - void decode_control_register_8(std::ostream &stream, uint32_t imm); - void decode_control_register_16(std::ostream &stream, uint32_t imm); - void decode_control_register_32(std::ostream &stream, uint32_t imm); + void decode_control_register_8(std::ostream &stream, uint8_t imm) override; + void decode_control_register_16(std::ostream &stream, uint8_t imm) override; + void decode_control_register_32(std::ostream &stream, uint8_t imm) override; private: static const char *const s_sfr_names[];