Beetle PCE and GPGX 1 Minute Freezes with CD Games (CHD related?)

This issue has been really sporadic to reproduce, so I haven’t made an issue report about it yet. Figured I’d bring it up here first to see if anyone else has run into this. Randomly, often during opening cutscenes, I’ve found CD games compressed as CHD in both Beetle PCE and Genesis Plus GX causing RetroArch to become unresponsive for around a minute. Video freezes, sound stops and I can’t bring up the menu or close RA normally. If I don’t try to bring up the task manager or tab out, it’ll start working again after a minute or so.

I tried enabling log to file to see if it had anything useful, but a Beetle PCE log that had a freeze compared to one that didn’t were pretty much identical. I just tried a redump bin/cue of Akumajou Dracula X: Chi no Rondo and couldn’t get it to freeze, but got one with a CHD conversion of it during the opening cutscene. I’m not 100% certain it’s CHD related though, since it’s random enough where I’ve had runs of the CHD where I couldn’t reproduce a freeze.

Other games I’ve had it happen with are: Dungeon Explorer II, Gate of Thunder (PCE Version), Ys Book I & II, Lunar: The Silver Star and Sonic CD. It always seems to happen when redbook audio is playing, so maybe it could be something weird with FLAC playback from the CHDs. I haven’t managed to repro it with games that don’t use redbook, like Popful Mail or Lunar II.

I’m on Win10 with a fairly recent RA nightly (C0482ff2ea). The cores are pretty up to date too (GPGX: a8645fb, Beetle PCE: 1a3c6e3). I’ve been messing around with runahead lately, but I’ve had this happen with it disabled. I don’t use rewind. I thought to try disabling some stuff like sync to exact content refresh and max swap chain 2 (I’ve only tested using Vulkan). I wasn’t able to get a freeze with those off, but it could have just been luck.

Also, I haven’t had similar freezes with CHD games in Beetle PSX or Saturn. Maybe I haven’t tried a game for those systems that uses redbook audio.

I don’t remember running into this issue when I was testing games when CHD was first introduced. Unfortunately I don’t remember when it first started happening either. I think maybe sometime fall of last year I had it first happen in Lunar, but I thought it was just a problem with that game. Couldn’t repro it then and forgot about it until now when I was testing several games and had it happen in more of them.

ill take a hard look at the health of your storage drives first if there has been any signs problems in the past. a quick SMART test would reveal this (dunno if ssd have similar tools). next is use another or make a new chd from a confirmed working image and use this instead.

i have worked on both of these cores are least for the past month for the CD-based retroachievements feature and i have not encountered such problems.

The “Akumajou Dracula X - Chi no Rondo (Japan) (FABT, FACT)” bin/cue was freshly grabbed, and I made the .chd that I got a freeze in yesterday from that. Normally I use an older dump that has the English text and audio patches applied, since I don’t think you can use those with the Redump dump. CrystalDiskInfo shows all my drives as Good, with the SSD at 94% health. I run these off one of the HDDs (1 TB 7200RPM WD Blue).

i would try running them off another drive. even at 100% health is unreliable if in the past the storage has some recent failures

heres an example of one of my mechanical storage. it says health is OK but a few months ago it had troubles accessing files from this drive. No relocated sectors noted, pending or uncorrectable sectors but it had a lasting 34 Uncorrectable Errors. I still use this till now though since the errors never increased or no new errors occured after after a full disk wipe was done (not ideal as its time consuming but it works for me).

I did some testing with a freshly unzipped RetroArch.7z win64 nightly in it’s own new folder. I wasn’t able to get any freezes with the bin/cue or chd versions of Rondo, but just got two freezes with a CHD of Dungeon Explorer II (USA). I waited at the title screen until the intro played and it happened around where it shows a picture of the character Riot, then again a few seconds after that. This should rule out any special settings I use with my normal install causing issues since all I changed from default was enabling fullscreen at start and exclusive fullscreen mode. This was the log it left: https://pastebin.com/CgLHTsRP

I’ll try testing a few more times with the CHD on another drive. I’d also like to see if I can get it to happen with a bin/cue. Here’s some SMART data from CrystalDisk on the HDD I have my CHD’s on now: https://pastebin.com/WxzvEviV

I extracted a newly grabbed Dungeon Explorer II (USA).7z and copied the folder to the SSD. I ran a chdman conversion there. I got a freeze right at the beginning of the opening cutscene. I don’t really think this is an issue with my drive…

I still can’t repro the freeze with the original bin/cue set on either drive. I’ll try a few more times later, but CHD is the only variable I think I’ve isolated as causing the issue.

Edit: I watched the entire DEII intro through three times using the bin/cue with no freezes. Tried the chd right after that and got a freeze. The freezes are pretty much always in different spots. Wish I could think of a good way to get some kind of debug info out of this.

any update? this kinda intrigues me…

I attempted getting the DEII bin/cue to freeze a few more times and couldn’t. But I also tried the chd again and couldn’t that time either. I had the idea to try the latest version of chdman to compress a new chd with to see if there were any differences. But it came out with the same md5 hash as my old one (540C24F099A16B6868723D2C011C483E).

Tried it just now with the chd of DEII and couldn’t get a freeze in the intro. But then tried my English patched Rondo chd and got one in it’s intro. It’s weird how DEII’s intro seemed to be the most consistent way I could get it to happen last time I posted, but now I can’t get it to.

I can’t think of any other weirdness happening with my machine that would point to my drives going bad. Native PC games, other emulated games and videos stored on the same drive all play perfectly. So if it is the hardware, this would be the first sign of any problem.

@Awakened I tried my CHD of Dungeon Explorer II, which has the same MD5 has as yours, and did not experience a freeze through 2 plays of the intro cutscene. I’ll try some others I have.

Update: Both Dracula X and Lunar Silver Star Story .CHD files played through their opening scenes without freezing on me.

Thanks for checking it out. I got another freeze today testing the chd DEII intro. I’ll just have to wait and see if anyone else reports similar issues and maybe switch back to bin/cue format and see if I ever get any freezes with those. Though I don’t really want to since I like the single compressed file style of chd.

i cannot launch even anything with pcsx now.

nevermind. core is working. no freezing here using chd.

Hello there! I have a similar problem with Saturn emulation using chd games. YabaSanshiro and Kronos give several small freezes in cinematics and even gameplay. Yabause completely freezes and crashes my computer. Only Beetle runs flawlessly. On the other hand, wilhe using BIN/CUE games all the emulators run with no freezes at all. (My setup: Ryzen 5 1600/ GTX 1050)