diff options
| author | 2008-12-11 09:40:22 +0000 | |
|---|---|---|
| committer | 2008-12-11 09:40:22 +0000 | |
| commit | d87ef8f79b70ca8117b8f365d4836ad4448086f7 (patch) | |
| tree | ae903a5c8f3aa26aca66e9425542e8b3d44c716a /src/emu/debug/debugcmd.c | |
| parent | c8944548df7b46b621039b1cea123b53c499664e (diff) | |
Here's the big one....
Added new function cpuexec_describe_context(machine) which can be
used in logerror() and other printf-style functions to return a
description of the current CPU/PC given only the machine. Changed
several dozen sites to use this instead of directly interrogating
the activecpu.
Removed all other uses of activecpu throughout the system. Removed
activecpu from the machine structure to prevent future abuse.
Removed cpu_push_context() and cpu_pop_context(), and all call
sites.
Voodoo devices now require a CPU to be defined in the configuration
in order to know whom to steal cycles from or stall when FIFOs get
full. Updated all voodoo users to specify one.
CPD1869 devices now also require a CPU to be defined in the
configuration, in order to know which CPU's registers to fetch.
Updated all cdp1869 users to specify one.
Many other small changes to make this all work.
Diffstat (limited to 'src/emu/debug/debugcmd.c')
| -rw-r--r-- | src/emu/debug/debugcmd.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/src/emu/debug/debugcmd.c b/src/emu/debug/debugcmd.c index 2e76b1240e1..e267e745406 100644 --- a/src/emu/debug/debugcmd.c +++ b/src/emu/debug/debugcmd.c @@ -1491,13 +1491,11 @@ static void execute_save(running_machine *machine, int ref, int params, const ch } /* now write the data out */ - cpu_push_context(space->cpu); for (i = offset; i <= endoffset; i++) { UINT8 byte = debug_read_byte(space, i, TRUE); fwrite(&byte, 1, 1, f); } - cpu_pop_context(); /* close the file */ fclose(f); @@ -1550,7 +1548,6 @@ static void execute_dump(running_machine *machine, int ref, int params, const ch } /* now write the data out */ - cpu_push_context(space->cpu); for (i = offset; i <= endoffset; i += 16) { char output[200]; @@ -1659,7 +1656,6 @@ static void execute_dump(running_machine *machine, int ref, int params, const ch /* output the result */ fprintf(f, "%s\n", output); } - cpu_pop_context(); /* close the file */ fclose(f); @@ -1733,7 +1729,6 @@ static void execute_find(running_machine *machine, int ref, int params, const ch } /* now search */ - cpu_push_context(space->cpu); for (i = offset; i <= endoffset; i += data_size[0]) { int suboffset = 0; @@ -1760,7 +1755,6 @@ static void execute_find(running_machine *machine, int ref, int params, const ch debug_console_printf(machine, "Found at %*X\n", space->logaddrchars, (UINT32)memory_byte_to_address(space, i)); } } - cpu_pop_context(); /* print something if not found */ if (found == 0) @@ -1809,7 +1803,6 @@ static void execute_dasm(running_machine *machine, int ref, int params, const ch } /* now write the data out */ - cpu_push_context(space->cpu); for (i = 0; i < length; ) { int pcbyte = memory_address_to_byte(space, offset + i) & space->bytemask; @@ -1898,7 +1891,6 @@ static void execute_dasm(running_machine *machine, int ref, int params, const ch /* output the result */ fprintf(f, "%s\n", output); } - cpu_pop_context(); /* close the file */ fclose(f); @@ -2011,7 +2003,6 @@ static void execute_history(running_machine *machine, int ref, int params, const cpuinfo = cpu_get_debug_data(space->cpu); /* loop over lines */ - cpu_push_context(space->cpu); for (i = 0; i < count; i++) { offs_t pc = cpuinfo->pc_history[(cpuinfo->pc_history_index + DEBUG_HISTORY_SIZE - count + i) % DEBUG_HISTORY_SIZE]; @@ -2033,7 +2024,6 @@ static void execute_history(running_machine *machine, int ref, int params, const debug_console_printf(machine, "%0*X: %s\n", space->logaddrchars, pc, buffer); } - cpu_pop_context(); } |
