summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/cpu/z80gb/z80gb.c
diff options
context:
space:
mode:
author Aaron Giles <aaron@aarongiles.com>2008-04-09 07:31:47 +0000
committer Aaron Giles <aaron@aarongiles.com>2008-04-09 07:31:47 +0000
commiteeee1cb4378411175c14fb463b58d97794063afb (patch)
treec60cf5c4b43311d0b604f82929108c6aa02a70da /src/emu/cpu/z80gb/z80gb.c
parent0a3bdaa3ef7730bc5b992a7077024f706a1c5c75 (diff)
Rewrote core memory handlers as inline functions. These should be easier to
trace through in a debug build, yet should operate the same as before. Created a complete set of functions for all databus sizes (8,16,32,64) and all endiannesses. A few functions are redundant, but it is now very clear which functions to use in which scenarios. It is also now possible to rely on being able to access values of 8, 16, 32 or 64 bits via the built-in accessors without fear of crashing. Updated all cores using 8-bit handlers to explicitly call the 8-bit handlers with the appropriate endianness. Fixed a few games which were calling n-bit handlers directly to use the generic forms. In the future, this is all the access drivers will have.
Diffstat (limited to 'src/emu/cpu/z80gb/z80gb.c')
-rw-r--r--src/emu/cpu/z80gb/z80gb.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/emu/cpu/z80gb/z80gb.c b/src/emu/cpu/z80gb/z80gb.c
index 003bc2e6794..08a44d5e10c 100644
--- a/src/emu/cpu/z80gb/z80gb.c
+++ b/src/emu/cpu/z80gb/z80gb.c
@@ -119,8 +119,8 @@ static z80gb_regs Regs;
/* Memory functions */
/****************************************************************************/
-#define mem_ReadByte(A) ((UINT8)program_read_byte_8(A))
-#define mem_WriteByte(A,V) (program_write_byte_8(A,V))
+#define mem_ReadByte(A) ((UINT8)program_read_byte_8le(A))
+#define mem_WriteByte(A,V) (program_write_byte_8le(A,V))
INLINE UINT16 mem_ReadWord (UINT32 address)
{