Previous 15994 Revisions Next

r14539 Sunday 19th February, 2012 at 23:01:35 UTC by R. Belmont
m68k: Add API to install a non-debugger instruction hook. Usage is strongly NOT recommended except for dire cases. [R. Belmont]
[src/emu/cpu]cpu.mak
[src/emu/cpu/m68000]m68000.h m68kcpu.c

src/emu/cpu/m68000/m68000.h
r14538r14539
122122void m68k_set_tas_callback(device_t *device, m68k_tas_func callback);
123123UINT16 m68k_get_fc(device_t *device);
124124
125
126typedef int (*instruction_hook_t)(device_t *device, offs_t curpc);
127void m68k_set_instruction_hook(device_t *device, instruction_hook_t ihook);
128
129
125130#endif /* __M68000_H__ */
src/emu/cpu/m68000/m68kcpu.c
r14538r14539
55#if 0
66static const char copyright_notice[] =
77"MUSASHI\n"
8"Version 4.90 (2011-09-22)\n"
8"Version 4.95 (2012-02-19)\n"
99"A portable Motorola M68xxx/CPU32/ColdFire processor emulation engine.\n"
1010"Copyright Karl Stenerud.  All rights reserved.\n"
1111"\n"
r14538r14539
1717"(Karl Stenerud).\n"
1818"\n"
1919"The latest version of this code can be obtained at:\n"
20"http://kstenerud.cjb.net or http://mamedev.org\n"
20"http://kstenerud.cjb.net or http://mamedev.org/\n"
2121;
2222#endif
2323
r14538r14539
12421242      /* --- the following bits of info are returned as NULL-terminated strings --- */
12431243      case DEVINFO_STR_NAME:                     /* set per-core */                  break;
12441244      case DEVINFO_STR_FAMILY:               strcpy(info->s, "Motorola 68K");      break;
1245      case DEVINFO_STR_VERSION:               strcpy(info->s, "4.90");            break;
1245      case DEVINFO_STR_VERSION:               strcpy(info->s, "4.95");            break;
12461246      case DEVINFO_STR_SOURCE_FILE:                  strcpy(info->s, __FILE__);            break;
1247      case DEVINFO_STR_CREDITS:               strcpy(info->s, "Copyright Karl Stenerud. All rights reserved. (2.1 fixes HJB, FPU+MMU by RB+HO)"); break;
1247      case DEVINFO_STR_CREDITS:               strcpy(info->s, "Copyright Karl Stenerud. All rights reserved. (2.1 fixes HJB, FPU+MMU by RB+HO+OG)"); break;
12481248   }
12491249}
12501250
r14538r14539
12651265   m68k->hmmu_enabled = enable;
12661266}
12671267
1268void m68k_set_instruction_hook(device_t *device, instruction_hook_t ihook)
1269{
1270   m68ki_cpu_core *m68k = get_safe_token(device);
1271
1272    m68k->instruction_hook = ihook;
1273}
1274
12681275/****************************************************************************
12691276 * 8-bit data memory interface
12701277 ****************************************************************************/
src/emu/cpu/cpu.mak
r14538r14539
11401140$(CPUOBJ)/m68000/m68kcpu.o:    $(CPUOBJ)/m68000/m68kops.c \
11411141                        $(CPUSRC)/m68000/m68kcpu.h $(CPUSRC)/m68000/m68kfpu.c $(CPUSRC)/m68000/m68kmmu.h
11421142
1143# m68kcpu.h now includes m68kops.h; m68kops.h won't exist until m68kops.c has been made
1144$(CPUSRC)/m68000/m68kcpu.h: $(CPUOBJ)/m68000/m68kops.c
11431145
11441146
11451147#-------------------------------------------------

Previous 15994 Revisions Next


© 1998-2018 The MESS Team