libretro / smsplus-gx

Improved port of SMSPlus-GX by gameblabla for libretro
12 stars 16 forks source link

[PSP] After starting a game, the console locks itself and shuts down #27

Closed Harry7228 closed 2 years ago

Harry7228 commented 3 years ago

When I use the SMS Plus GX core on PSP for playing a Game Gear or Master System game in RetroArch the game starts, but every game locks the console. Sometimes it is already after several seconds, sometimes it happends when 'in' game. I have tested it on two different PSP consoles. I use the last nightly version of RetroArch. (Used core version: 1.9.4 - SMS Plus GX (1.8 2041426)

PootyLimbo commented 3 years ago

It looks to me like the horizontal hardware scrolling is causing this. Sonic 2 and Lemmings crash immediately, Fantasy Zone crashes as the gameplay starts, Alex Kidd in Miracle World crashes shortly after going underwater in the first level (ruling out vertical scrolling), and Ultima IV doesn't seem to crash at any point during normal gameplay (although it does crash after watching the demo due to the shimmering effect).

negativeExponent commented 2 years ago

@Harry7228 @PootyLimbo I cannot replication this on latest. Please try if this still happens in latest version. If it still does, go to core options and disable FM (ym2413) and see if it works.

jSTE0 commented 2 years ago

Could this be related to unaligned memory access? The PSP uses a MIPS R4000 which AIUI results in a bus error when attempting a load or store at an misaligned memory address. I've been looking into this as part of #38 and the PSP build is missing a -DALIGN_DWORD. If a PSP dev can confirm this, I can just squash it into the PR.

jSTE0 commented 2 years ago

Looking around libretro/QuickNES_Core#71 describes a crash due to unaligned memory access and the standalone port does specify -DALIGN_DWORD so I'll raise a PR. Hopefully it fixes this but at least it won't make it worse.