all repos — mgba @ ad02a0e0f38b8de7f35cb6c5e72c0836d47f276f

mGBA Game Boy Advance Emulator

GBA: More warning fixes
Vicki Pfau vi@endrift.com
Thu, 27 Feb 2020 21:13:47 -0800
commit

ad02a0e0f38b8de7f35cb6c5e72c0836d47f276f

parent

9849af532cace421336fc86bfb32dffb0aa92417

2 files changed, 4 insertions(+), 5 deletions(-)

jump to
M src/gba/gba.csrc/gba/gba.c

@@ -51,7 +51,7 @@ static void _triggerIRQ(struct mTiming*, void* user, uint32_t cyclesLate);

#ifdef USE_DEBUGGERS static bool _setSoftwareBreakpoint(struct ARMDebugger*, uint32_t address, enum ExecutionMode mode, uint32_t* opcode); -static bool _clearSoftwareBreakpoint(struct ARMDebugger*, uint32_t address, enum ExecutionMode mode, uint32_t opcode); +static void _clearSoftwareBreakpoint(struct ARMDebugger*, const struct ARMDebugBreakpoint*); #endif #ifdef FIXED_ROM_BUFFER

@@ -918,8 +918,7 @@ GBASetBreakpoint((struct GBA*) debugger->cpu->master, &debugger->d.p->d, address, mode, opcode);

return true; } -static bool _clearSoftwareBreakpoint(struct ARMDebugger* debugger, uint32_t address, enum ExecutionMode mode, uint32_t opcode) { - GBAClearBreakpoint((struct GBA*) debugger->cpu->master, address, mode, opcode); - return true; +static void _clearSoftwareBreakpoint(struct ARMDebugger* debugger, const struct ARMDebugBreakpoint* breakpoint) { + GBAClearBreakpoint((struct GBA*) debugger->cpu->master, breakpoint->d.address, breakpoint->sw.mode, breakpoint->sw.opcode); } #endif
M src/gba/renderers/software-obj.csrc/gba/renderers/software-obj.c

@@ -158,7 +158,7 @@ int32_t x = (uint32_t) GBAObjAttributesBGetX(sprite->b) << 23;

x >>= 23; x += renderer->objOffsetX; uint16_t* vramBase = &renderer->d.vram[BASE_TILE >> 1]; - bool align = GBAObjAttributesAIs256Color(sprite->a) && !GBARegisterDISPCNTIsObjCharacterMapping(renderer->dispcnt); + unsigned align = GBAObjAttributesAIs256Color(sprite->a) && !GBARegisterDISPCNTIsObjCharacterMapping(renderer->dispcnt); unsigned charBase = (GBAObjAttributesCGetTile(sprite->c) & ~align) * 0x20; if (GBARegisterDISPCNTGetMode(renderer->dispcnt) >= 3 && GBAObjAttributesCGetTile(sprite->c) < 512) { return 0;