DS Memory: Ensure DS9 I/O is 8-byte aligned

This commit is contained in:
Vicki Pfau 2017-04-10 20:20:53 -07:00
parent 9379290050
commit 4ab96b42a0
3 changed files with 4 additions and 1 deletions

View File

@ -8,6 +8,7 @@ Bugfixes:
- DS GX: Fix 4-color texture coordinates
Misc:
- DS: Set boot complete bit in RAM on boot (fixes mgba.io/i/576, mgba.io/i/580, mgba.io/i/586)
- DS Memory: Ensure DS9 I/O is 8-byte aligned
0.6.0: (Future)
Features:

View File

@ -153,9 +153,11 @@ typedef intptr_t ssize_t;
#ifdef _MSC_VER
#define ATTRIBUTE_UNUSED
#define ATTRIBUTE_ALIGN(X)
#define ATTRIBUTE_FORMAT(X, Y, Z)
#else
#define ATTRIBUTE_UNUSED __attribute__((unused))
#define ATTRIBUTE_ALIGN(X) __attribute__((aligned(X)))
#define ATTRIBUTE_FORMAT(X, Y, Z) __attribute__((format(X, Y, Z)))
#endif

View File

@ -90,7 +90,7 @@ struct DSMemory {
uint32_t* wram7;
uint32_t* rom;
uint16_t io7[DS7_REG_MAX >> 1];
uint16_t io9[DS9_REG_MAX >> 1];
uint16_t io9[DS9_REG_MAX >> 1] ATTRIBUTE_ALIGN(8);
struct DSSlot1 slot1;
struct DSSPIBus spiBus;