Debugger: Align PC-relative loads in Thumb
Jeffrey Pfau jeffrey@endrift.com
Thu, 25 Dec 2014 02:37:26 -0800
2 files changed,
2 insertions(+),
1 deletions(-)
M
CHANGES
→
CHANGES
@@ -28,6 +28,7 @@ - GBA Video: Fix blend issues with obscured middle layers
- Video: Ensure FFmpeg encoder has audio frames - Video: Fix uncompressed PCM audio recording - GBA Video: Fix windows not disabling target 1 appropriately (fixes #161) + - Debugger: Align PC-relative loads in Thumb Misc: - Qt: Disable sync to video by default - GBA: Exit cleanly on FATAL if the port supports it
M
src/arm/decoder.c
→
src/arm/decoder.c
@@ -127,7 +127,7 @@ ADVANCE(1);
int written; if (memory.format & ARM_MEMORY_REGISTER_BASE) { if (memory.baseReg == ARM_PC && memory.format & ARM_MEMORY_IMMEDIATE_OFFSET) { - written = _decodePCRelative(memory.format & ARM_MEMORY_OFFSET_SUBTRACT ? -memory.offset.immediate : memory.offset.immediate, pc, buffer, blen); + written = _decodePCRelative(memory.format & ARM_MEMORY_OFFSET_SUBTRACT ? -memory.offset.immediate : memory.offset.immediate, pc & 0xFFFFFFFC, buffer, blen); ADVANCE(written); } else { written = _decodeRegister(memory.baseReg, buffer, blen);