Saturn Kronos core crashes on save state?! (Help!)

The good news is that we passed the first crash, the bad news is that it crashed later. Long story short it seems your system crash every time it encounters the fprintf function for some reason, but it seems we can get around this issue by using another function called fwrite.

I pushed another commit to try to fix this (will be 3980e76 i think ?), let me know how it turns out when it’ll be available from the online updater.

Here is the log. It doesn’t crash at save state now but now it doesn’t save a state at all. I get a message saying : “This core doesn’t support save states”.

Yeah, i noticed this afternoon that we never checked if the tmpfile was created or not before trying to write on it, because as far as we knew there was no reason for the OS to reject creating tmpfiles, it turns out we were wrong, apparently your setups won’t create tmpfiles (and i’ve still no idea why), and the crash happened because we were trying to write on that non-existent file.

I intend to rewrite the savestate code in Kronos in the next few weeks, so that it doesn’t rely on tmpfile creation at all.

That would be great thank you! If you update Kronos will the other Saturn cores be updated as well like the Yabause core?

I intend to backport the “fix” that check if the tmpfile is created to Yabause, nothing else.

Sorry I hadn’t seen your post… Core is latest version and using Kronos, not “old”, I just thought I would try a random setting “share save states with Beetle”… but still insta crash on save state.

Kronos standalone saves state fine but I can’t get any game to boot once controller settings are done (same with Yaba standalone). I have nothing but nightmares with the standalone of both so I deleted them both.

I will do what you asked sometime today… where is that log even located?

Edit: I just enabled core logging to 0, loaded the game in Kronos, tried to save state and crash of course, and now I went into a folder called “logs” in retroarch and it’s completely empty.

Read my post above, the crash has already been fixed if you update to latest version of the core.

[BarbuDreadMon] “I intend to rewrite the savestate code in Kronos in the next few weeks, so that it doesn’t rely on tmpfile creation at all.” I intend to backport the “fix” that check if the tmpfile is created to Yabause, nothing else.

So which core are you rewriting the savestate for? Kronos core or Yabause core?

I’m working on the Kronos core, and while i backport some stuff to the Yabause core from time to time, i only does it for simple ones.

The only way I know how to update to the latest version of the core is through retroarch.

Edit, ok the crash is fixed but I get the message “Core does not support save states”.

When i say to read my post above, that’s because i want you to read it…

I read it, then I read the one where you told me to read it… I got confused cause when you said the crash was already fixed, to ME that reads that the problem has been fixed. So on one hand I thought you were saying it would be a few weeks and on the other that it was fixed already. I was simply reporting.

As already explained the issue is that your setup refuse to create tmpfiles (probably some shitty rights issue, i wouldn’t be surprised if executing RA as admin was a workaround), and that’s why it was crashing when trying to write on that tmpfile. Now the savestate process properly stop if your OS refuse to create the tmpfile.

As for the complete rewrite of the savestate process to avoid having to use a tmpfile, it’ll take time, weeks, maybe months, because tbh i have other things to do.

1 Like

Okay, so you’re fixing/rewriting the Kronos core so anyone with a SSD can make save states. Got it. Thanks again for doing this!

I forgot to mention this : i got a friend with both a SSD and a normal HDD to do some tests, he had the issue whatever disk he used, so that’s not a SSD issue. Right now i have higher suspicions about privileges since the microsoft documentation mentions administrative privileges being required for this function on vista (WTF windows ? That’s just a temp file, why do you require administrative privileges to create it ?). I think executing RA as admin might get around this.

1 Like

I am happy to run it as an admin but since save functionality has been removed in the latest core, we can’t now. If there’s some way to temporarily reinstate it very briefly I will try it. If that fixes the problem then we are set till you make the fix.

Running in Admin lets me save and load the state! Just tested it!

1 Like

That’s why I always disabled UAC on my home computers. Just disable UAC completely and you don’t need to explicitly start any program as Administrator, in fact when you run windows for the first time and create your user account for the system (the OOEB wizard), the account created is member of Administrators local group, the “security feature” :laughing: that control that annoying behavior of running programs in a lower privileges security context is UAC (User Account Control). You can disable it in various way, I personally prefer the Local Group Policy Editor way.

Win Key + R -> GPEDIT.MSC -> Enter

In the Group Policy Editor window, browse to Computer Configuration > Windows Settings > Security Settings > Local Policies > Security Options.

Make the following changes:

User Account Control: Behavior of the elevation prompt for administrators in Admin Approval Mode – Set its value to Elevate without prompting.
User Account Control: Detect application installations and prompt for elevation – Set its value to Disabled.
User Account Control: Only elevate UIAccess applications that are installed in secure locations – Set its value to Disabled.
User Account Control: Run all administrators in Admin Approval Mode – Set its value to Disabled.

Restart the computer. Also, you can search on google “How to disable UAC on Windows 10”

That way, since your account is already member of the local Administrators group, all the programs you run in your windows session, run with the highest OS privileges, and without security elevation prompts. Basically, you will really 99% own your computer, except for certain process/OS services/folders/registry keys/etc that run on the SYSTEM’s accounts. Those too can be modified by taking ownership of the respective objects, but that is another story, Windows Advanced Security shenanigans. :wink:

It never was removed, you should really start reading what i said in this topic, this is getting tiring…

I have a question: what is the best shader to use with 3D Saturn games? Anything that can further smooth out the pixels/graphics?

If not that’s fine because Kronos already upscales the graphics. Just for fun I tried a game in the Yabause core and everything was a pixelated mess! Kronos looks miles better with its bilinear filtering!