all repos — mgba @ c134c6cae197d933ecb0bec1d91cc422eccd0c7b

mGBA Game Boy Advance Emulator

ARM: Don't force passed opcodes to be truncated
Vicki Pfau vi@endrift.com
Wed, 13 Jun 2018 18:42:18 -0700
commit

c134c6cae197d933ecb0bec1d91cc422eccd0c7b

parent

bf2cdbacb6037f3bd07f41db62fcb17eda77de10

2 files changed, 2 insertions(+), 2 deletions(-)

jump to
M include/mgba/internal/arm/isa-thumb.hinclude/mgba/internal/arm/isa-thumb.h

@@ -12,7 +12,7 @@ CXX_GUARD_START

struct ARMCore; -typedef void (*ThumbInstruction)(struct ARMCore*, uint16_t opcode); +typedef void (*ThumbInstruction)(struct ARMCore*, unsigned opcode); extern const ThumbInstruction _thumbTable[0x400]; CXX_GUARD_END
M src/arm/isa-thumb.csrc/arm/isa-thumb.c

@@ -56,7 +56,7 @@ #define THUMB_STORE_POST_BODY \

currentCycles += cpu->memory.activeNonseqCycles16 - cpu->memory.activeSeqCycles16; #define DEFINE_INSTRUCTION_THUMB(NAME, BODY) \ - static void _ThumbInstruction ## NAME (struct ARMCore* cpu, uint16_t opcode) { \ + static void _ThumbInstruction ## NAME (struct ARMCore* cpu, unsigned opcode) { \ int currentCycles = THUMB_PREFETCH_CYCLES; \ BODY; \ cpu->cycles += currentCycles; \