mirror of
https://github.com/holub/mame
synced 2025-05-25 15:25:33 +03:00
Fix fatal pointer truncation on 64-bit builds.
This commit is contained in:
parent
4f266b6da4
commit
84afc85712
@ -74,10 +74,17 @@ struct _cpu_config
|
|||||||
CPU DEVICE CONFIGURATION MACROS
|
CPU DEVICE CONFIGURATION MACROS
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
#ifdef PTR64
|
||||||
|
#define MDRV_CPU_ADD(_tag, _type, _clock) \
|
||||||
|
MDRV_DEVICE_ADD(_tag, CPU) \
|
||||||
|
MDRV_DEVICE_CONFIG_DATA64(cpu_config, type, CPU_##_type) \
|
||||||
|
MDRV_DEVICE_CONFIG_DATA32(cpu_config, clock, _clock)
|
||||||
|
#else
|
||||||
#define MDRV_CPU_ADD(_tag, _type, _clock) \
|
#define MDRV_CPU_ADD(_tag, _type, _clock) \
|
||||||
MDRV_DEVICE_ADD(_tag, CPU) \
|
MDRV_DEVICE_ADD(_tag, CPU) \
|
||||||
MDRV_DEVICE_CONFIG_DATA32(cpu_config, type, CPU_##_type) \
|
MDRV_DEVICE_CONFIG_DATA32(cpu_config, type, CPU_##_type) \
|
||||||
MDRV_DEVICE_CONFIG_DATA32(cpu_config, clock, _clock)
|
MDRV_DEVICE_CONFIG_DATA32(cpu_config, clock, _clock)
|
||||||
|
#endif
|
||||||
|
|
||||||
#define MDRV_CPU_REMOVE(_tag) \
|
#define MDRV_CPU_REMOVE(_tag) \
|
||||||
MDRV_DEVICE_REMOVE(_tag, CPU)
|
MDRV_DEVICE_REMOVE(_tag, CPU)
|
||||||
@ -85,11 +92,19 @@ struct _cpu_config
|
|||||||
#define MDRV_CPU_MODIFY(_tag) \
|
#define MDRV_CPU_MODIFY(_tag) \
|
||||||
MDRV_DEVICE_MODIFY(_tag, CPU)
|
MDRV_DEVICE_MODIFY(_tag, CPU)
|
||||||
|
|
||||||
|
#ifdef PTR64
|
||||||
|
#define MDRV_CPU_REPLACE(_tag, _type, _clock) \
|
||||||
|
MDRV_DEVICE_REMOVE(_tag, CPU) \
|
||||||
|
MDRV_DEVICE_ADD(_tag, CPU) \
|
||||||
|
MDRV_DEVICE_CONFIG_DATA64(cpu_config, type, CPU_##_type) \
|
||||||
|
MDRV_DEVICE_CONFIG_DATA32(cpu_config, clock, _clock)
|
||||||
|
#else
|
||||||
#define MDRV_CPU_REPLACE(_tag, _type, _clock) \
|
#define MDRV_CPU_REPLACE(_tag, _type, _clock) \
|
||||||
MDRV_DEVICE_REMOVE(_tag, CPU) \
|
MDRV_DEVICE_REMOVE(_tag, CPU) \
|
||||||
MDRV_DEVICE_ADD(_tag, CPU) \
|
MDRV_DEVICE_ADD(_tag, CPU) \
|
||||||
MDRV_DEVICE_CONFIG_DATA32(cpu_config, type, CPU_##_type) \
|
MDRV_DEVICE_CONFIG_DATA32(cpu_config, type, CPU_##_type) \
|
||||||
MDRV_DEVICE_CONFIG_DATA32(cpu_config, clock, _clock)
|
MDRV_DEVICE_CONFIG_DATA32(cpu_config, clock, _clock)
|
||||||
|
#endif
|
||||||
|
|
||||||
#define MDRV_CPU_FLAGS(_flags) \
|
#define MDRV_CPU_FLAGS(_flags) \
|
||||||
MDRV_DEVICE_CONFIG_DATA32(cpu_config, flags, _flags)
|
MDRV_DEVICE_CONFIG_DATA32(cpu_config, flags, _flags)
|
||||||
|
Loading…
Reference in New Issue
Block a user