summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author AJR <ajrhacker@users.noreply.github.com>2019-07-04 00:45:10 -0400
committer AJR <ajrhacker@users.noreply.github.com>2019-07-04 00:48:41 -0400
commit345e5e2dc18ea65c5143c110d54da1560f6d9dd0 (patch)
tree39c8fdc7c03c5a2950b60a72660c92525138d564
parent9955eed5d2273ff90d448cb36144e0c16df0e7d8 (diff)
Fix calculation of TMS34010/020 shifted memory addresses for debug save and load commands
-rw-r--r--src/emu/debug/debugcmd.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/emu/debug/debugcmd.cpp b/src/emu/debug/debugcmd.cpp
index 66bc8578464..fdf08ca0ca4 100644
--- a/src/emu/debug/debugcmd.cpp
+++ b/src/emu/debug/debugcmd.cpp
@@ -1889,7 +1889,7 @@ void debugger_commands::execute_save(int ref, const std::vector<std::string> &pa
endoffset &= ~15;
for (offs_t i = offset; i != endoffset; i+=16)
{
- offs_t curaddr = i >> 4;
+ offs_t curaddr = i;
u16 data = space->device().memory().translate(space->spacenum(), TRANSLATE_READ_DEBUG, curaddr) ?
space->read_word(curaddr) : space->unmap();
fwrite(&data, 2, 1, f);
@@ -1993,7 +1993,7 @@ void debugger_commands::execute_load(int ref, const std::vector<std::string> &pa
endoffset &= ~15;
for (i = offset; f.good() && (i <= endoffset || endoffset == offset - 16); i+=16)
{
- offs_t curaddr = i >> 4;
+ offs_t curaddr = i;
u16 data;
f.read((char *)&data, 2);
if (f && space->device().memory().translate(space->spacenum(), TRANSLATE_WRITE_DEBUG, curaddr))