libretro / beetle-psx-libretro

Standalone port/fork of Mednafen PSX to the Libretro API.
GNU General Public License v2.0
309 stars 131 forks source link

Can't start any game with GTE Overclock, CPU Frequency scaling or GPU rasteriser enabled. #513

Open damianshrinivas opened 5 years ago

damianshrinivas commented 5 years ago

Description

Recently I can't start any game with GTE Overclock, CPU Frequency scaling or GPU rasteriser overclock enabled in Retroarch 1.7.7.

Expected behavior

Booting normally like before.

Actual behavior

With any of the overclock option enabled prior to booting the game, actual game won't boot. With these options disabled game will boot normally. It is a problem for about a week, it was working fine before.

Steps to reproduce the bug

  1. Enable any form of overclocking before starting the game.
  2. Start the game
  3. Game will be stuck on the playstation logo (Croc Legend Of The Gobbos as an example plus many, many more)

Bisect Results

From like a week ago, I updated the core yesterday. And I'm updating it pretty often so this is fresh.

Version/Commit

[Retroarch 1.7.7]

Core options

GTE Overclock, CPU Frequency scaling or GPU rasteriser changed to anything else than the defaults before booting the game.

Environment information

rz5 commented 5 years ago

I can confirm that, assuming 'Skip BIOS' is off:

However if you set 'GPU rasterizer overclock' to 32x, which I assume is the worst case for causing glitches, it will not get stuck like the other 2 options. What does happen is that in the Sony logo screen, the inner triangles get flickery and stretched, not too dissimilar when PGXP's mode is 'memory + CPU'.

damianshrinivas commented 5 years ago

Yes, skip bios is off. I had GTE Overclock and Rasterizer 32x turned on all the time and had no glitches, now I have to change it all the time. Even with skip bios off some games will get stuck on the loading screen while booting.

rz5 commented 5 years ago

It may have been because of the recent commit that some changes done in Mednafen 1.22.2. I'll have to test to confirm it, but if that was it, this bug won't be fixed. That specific commit fixed 11 games. These overclock options were added as neat hacks but they cause issues like these.

damianshrinivas commented 5 years ago

Is there any place that I can obtain older version of the core?

rz5 commented 5 years ago

@damianshrinivas Here's a Windows x86_64 build of commit 53591985319edc34d83a0858ad9a935b934dcf5c, before I merged the cherrypicked stuff from upstream.

mednafen_psx_hw_libretro.zip

damianshrinivas commented 5 years ago

thank you

inactive123 commented 5 years ago

@rz5 This is very bad though, and I definitely would suggest that if you can't fix them, we create a separate repo with these changes in it, while still having a Beetle PSX that has all these features working. I absolutely do not want to start sacrificing these features. Maybe this could be the more 'upstream-aligned' Mednafen PSX version that some desire.

@simias Maybe you can help us fix these issues? We need somebody who can backport these changes to the latest Mednafen version.

rz5 commented 5 years ago

All these overclock features are not stable in the long run. A game will eventually hang - you may be able to recover by changing to default settings on-the-fly - or outright crash leaving you in a blank screen. The only OC option that does some amount of checking is the CD fastload stuff, which e.g. reverts back to slower speeds when playing back CDDA content.

Technically, because these features are not stable in the context of a long play session, they are as broken as they were before. The cherrypick commit clearly fixes 11 games. (Assuming that commit is the cause of this bug thread) the consequence of that commit is that the OC options now cause hangs in different places.

damianshrinivas commented 5 years ago

I've completed more than 10 games including FF series, Tomb Raider 1-5 and none of them hanged before with gte overclock on and rasterizer set to 32x so I dunno. They were pretty stable. And I can only suggest that if it won't work, just delete the overclock options completely, cause there will be more started issues with the same thing in the future, here or in the retroarch repo.

inactive123 commented 5 years ago

GTE Overclock is very important to me. We absolutely have to find a solution to this.