Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

possibly adding Save State #2494

Open
JackTheRipper47 opened this issue Apr 13, 2023 · 9 comments
Open

possibly adding Save State #2494

JackTheRipper47 opened this issue Apr 13, 2023 · 9 comments

Comments

@JackTheRipper47
Copy link

Hi, not really an issue but didn't know where else to post. Is it possible to add save states to the emulator? similar to PCSX2 or PPSSPP, that would be great if crashes happen as well cause you could just load..

anyway thanks in advance.

@JackTheRipper47 JackTheRipper47 changed the title Save State possibly adding Save State Apr 13, 2023
@CoffeeBrewer64
Copy link
Contributor

the problem with save states for vita3k is that the ram is 512mb. plus some other data (CPU instructions, GPU state, etc.).

so, every single save state would be over 512mb in a single file. one of those might be okay, but the 2 or 3 states people keep on other emulators would be too much to use.

also, not everyone has an SSD. hard drives have to use a needle and some other stuff, which will always be slower than an SSD, which uses electrons and metal.

also also, android has some kind of limit on how large files can be from one call (or something like that, it might be in older versions)

@JackTheRipper47
Copy link
Author

JackTheRipper47 commented Apr 13, 2023 via email

@CoffeeBrewer64
Copy link
Contributor

agreed, but we would probably have to wait for faster and larger storage devices and ram to become more mainstream. give it a few years and save states might be a thing.

@nn9dev
Copy link
Contributor

nn9dev commented Apr 13, 2023

I dunno about YEARS...

There's a taiHEN plugin that implements save states on a physical Vita, which is pretty impressive. The downside though is that yes, they do take up 500+ MB per save state, and they take about ~30-60s to create and save each save state. TaiHEN plug-ins aren't supported on Vita3K, however, and they probably won't be for a bit.

Theoretically, someone could implement save states without it being TOO grueling of a process (I mean, save states are practically a glorified RAM dump), but things are constantly changing and being updated in the emulator, thus producing inconsistencies. The goal would be to have as many inconsistencies worked out as possible before implementing something that relies on. Well. Consistency.

Not to mention there's a lot of other stuff that still needs to be worked on: graphics, audio, etc.

TL;DR, entirely possible, probably not soon.

@mcabel
Copy link

mcabel commented May 13, 2023

One "workaround" the 512mb problem, is a configuration option that lets you choose how many savestate slots the user want available, and maybe separate that disk space (with a dummy 512mb savestate or something), so the user will always have enough disk available for the amount of savestate slots they chose. For most people, 1024mb+ , for 2 slots is probably not a deal breaker I believe.

@CoffeeBrewer64
Copy link
Contributor

True, but what about read write speeds? not everyone has an SSD. and the file size of 512mb would still be present. but a dummy file is a good idea

@nn9dev
Copy link
Contributor

nn9dev commented May 13, 2023

There's honestly no need for any of that. A check before creating the save state for storage makes that a non-issue. And it's far less of an issue, and more of simply an "annoyance", that each save state has the potential to be the size of a whole game.

Additionally, a SSD isn't even really needed. Most hard drives these days have write speeds of upwards of 150MB/s, (so, ~3.5s to write 512MB) and even if you have an older one you're probably still not really gonna suffer much from ONE 512MB write. Even your average 2011 hard drive begins to boast ~70MB/s+ (~7.3s to write 512MB)

So again, the limitations truly aren't physical or even technical, but more that it's just a bit of an annoyance and that it hasn't been done yet (and mostly that there's just some other focuses).

@Macdu
Copy link
Contributor

Macdu commented May 13, 2023

the problem with save states for vita3k is that the ram is 512mb. plus some other data (CPU instructions, GPU state, etc.).

so, every single save state would be over 512mb in a single file. one of those might be okay, but the 2 or 3 states people keep on other emulators would be too much to use.

also, not everyone has an SSD. hard drives have to use a needle and some other stuff, which will always be slower than an SSD, which uses electrons and metal.

also also, android has some kind of limit on how large files can be from one call (or something like that, it might be in older versions)

That's kinda wrong, the PS Vita indeed has 512 MB of RAM. However, most games do not use half of it. Moreother, a good chunk of the memory used by the PS Vita is not used by Vita3K because of HLE emulation (no need for many low level files and many graphics buffers). Finally, compressing the data before writing it would be really effective as most of what takes space has a really low entropy. The PS3 has 512MB of memory and RPCS3 has save states.

The main issue is that it's really hard and annoying to implement and make it right (you basically have to serialize/unserialize the whole emulator state)

@memory-hunter
Copy link

Where RPCS3 managed to implement it, it think it is viable for Vita3K too

the problem with save states for vita3k is that the ram is 512mb. plus some other data (CPU instructions, GPU state, etc.).

so, every single save state would be over 512mb in a single file. one of those might be okay, but the 2 or 3 states people keep on other emulators would be too much to use.

also, not everyone has an SSD. hard drives have to use a needle and some other stuff, which will always be slower than an SSD, which uses electrons and metal.

also also, android has some kind of limit on how large files can be from one call (or something like that, it might be in older versions)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants