Gericom / GBARunner3

205 stars 28 forks source link

Golden Sun 2: The Lost Age has random audio crackling #31

Closed Dartz150 closed 5 months ago

Dartz150 commented 11 months ago

This happens either when save data is being loaded or in-game. The crackling has a weird echo, compared to other games that have crackling.

Apparently disabling cache makes this less frequent, but still sometimes audible, specially on the opening cutscene.

Dartz150 commented 10 months ago

Update as from latest commit 356ee56:

As explained by Sono in the Discord chat while talking about the Mother 3 HQ Audio Mixing hack, which uses this, the HQ sound mixer uses self-modifying code. Since this game is where that HQ mixer was based/reversed from, it means that it also has self-modifying code,

Turning off iCache is now possible to do per-game, so doing so for this, fixes the random screech issue.

However, on DSi mode, there's still some sound wobbling due to SD fetches, and in DS mode, there are major performance drops in the overworld maps, so it should be seen as a temporary fix, just like how it is for Smashing Drive for example.

An advantage we have with this case, is that the HQ mixer source code is available, so it should be possible to implement a way to patch-in cache invalidation when the code self-modifies.

Dartz150 commented 9 months ago

Random sound performance was fixed with 14b27ce, and the sound wobbling while opening the savegame menu has been fixed since cc9caf6, it still needs wram icache turned off because of the self-modifying code

Gericom commented 8 months ago

With the new self modifying patches, only iwram dcache needs to be turned on still to fully fix this

Dartz150 commented 5 months ago

This has been fully fixed an tested as properly working on the latest commit 90b994f