VOGONS


First post, by accipiter

User metadata
Rank Newbie
Rank
Newbie

u know, many games doesnt provide a convenient save mechanism.
so i want to know if dosbox support or will support a function, which can capture and save the memory to file?

Reply 1 of 12, by ADDiCT

User metadata
Rank Oldbie
Rank
Oldbie

Nope, it doesn't. The feature would be quite nice to have, but according to the devs, it's very hard to implement "Save States" in DOSBox. Remember, we're dealing with a system that's quite complex in terms of both hard- and software.

Reply 2 of 12, by jal

User metadata
Rank Oldbie
Rank
Oldbie
ADDiCT wrote:

Nope, it doesn't. The feature would be quite nice to have, but according to the devs, it's very hard to implement "Save States" in DOSBox. Remember, we're dealing with a system that's quite complex in terms of both hard- and software.

It's not very hard to implement per se, it's just that it was never designed from the start to ever be able to do this, and trying to apply it retro-actively is really, really hard, given the number of configurations supported.

JAL

Reply 3 of 12, by ripsaw8080

User metadata
Rank DOSBox Author
Rank
DOSBox Author

It's my opinion that save-states are always problematic when storage devices (disks) are involved, because in a sense they are a sort of memory that is tied into the "state" of the system. Imagine a worst-case scenario where you take a snapshot of the system while it is in the middle of doing an install... you practically have to save the contents of the disk as part of the state in order for it to be valid when restored.

Reply 4 of 12, by wd

User metadata
Rank DOSBox Author
Rank
DOSBox Author

Some parts in dosbox contain recursion (pagefaults, keyboard input/tsr capturing)
and this part remains unresolved.

Reply 5 of 12, by jal

User metadata
Rank Oldbie
Rank
Oldbie
ripsaw8080 wrote:

It's my opinion that save-states are always problematic when storage devices (disks) are involved

Yes, storage devices are an extra pain, at least when you don't tie them in with the state saving.

you take a snapshot of the system while it is in the middle of doing an install... you practically have to save the contents of the disk as part of the state in order for it to be valid when restored.

Indeed. At least, you cannot start another snapshot on the same disk.

JAL

Reply 6 of 12, by jal

User metadata
Rank Oldbie
Rank
Oldbie
wd wrote:

Some parts in dosbox contain recursion (pagefaults, keyboard input/tsr capturing) and this part remains unresolved.

Very problematic areas, though if designed from the start to support state-saving, defintely not impossible. I take it currently DOSbox uses the system stack for this recursion, so I understand it is impossible to save properly.

Note: I'm not advocating DOSbox should ever attempt to do a save-state implementation. I know some of you guys get irritated when someone does, and I wouldn't inadvertently irritate you 😀.

JAL

Reply 7 of 12, by wd

User metadata
Rank DOSBox Author
Rank
DOSBox Author

Oh irritations aren't that bad. It was said that using an emulated dos it would
not be possible to run win3x in enhanced mode.

There are some ideas to avoid the recursions or work around it (actually the
places where removing it are already handled), like disallowing saving when
pagefaults are active.

Reply 8 of 12, by Harekiet

User metadata
Rank DOSBox Author
Rank
DOSBox Author

yeh could just postpone the saving till the machine is in a state that allows it.

Reply 9 of 12, by ih8registrations

User metadata
Rank Oldbie
Rank
Oldbie

Another trick would be for those trouble parts, use a static workable state that you insert for the restore. If you don't need exact for some or all areas, that might get it over the hump to have a workable save state.

Reply 10 of 12, by wd

User metadata
Rank DOSBox Author
Rank
DOSBox Author

Feel free to try it, especially for the keyboard input and recursive command shells.

Reply 11 of 12, by ih8registrations

User metadata
Rank Oldbie
Rank
Oldbie

Where do you see recursive command shell use?

Reply 12 of 12, by wd

User metadata
Rank DOSBox Author
Rank
DOSBox Author

Whenever command.com is called from an app.