Save States - Proof of concept

Here you can discuss the development of patches.

Re: Save States - Proof of concept

Postby eL_PuSHeR » 2012-5-25 @ 17:22

[Thread moved to DOSBox Development Section as suggested]
User avatar
eL_PuSHeR
Moderator
 
Posts: 6451
Joined: 2003-6-20 @ 16:39

Re: Save States - Proof of concept

Postby tikalat » 2012-5-26 @ 13:42

Code: Select all
003

direct3d.cpp
+ Allow stretch-to-window Direct3D fullscreen feature (autofit=true + aspect=true + fullscreen=original)

dosbox.cpp
+ Add 'autofit' option



004

midi.cpp
+ Do manual device reset (turn off notes, controllers) on open
(seems to fix random Roland VSC -system- crashes from bad VSC states)


Test build (new dosbox.conf included)
http://www.sendspace.com/file/3g9kr8



TODO:
- May add new mixer savestate idea (only save/load devices that are created)
- May add Innova savestate
- May add Adlib savestate
- Look at paging again
- Experimenting with something called win32 shark_cheater (see ngemu forums - ePSxe_shark) (can't contact original author but seems free source) (modifying for possible relocatable RAM)
You do not have the required permissions to view the files attached to this post.
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

Re: Save States - Proof of concept

Postby robertmo » 2012-5-26 @ 14:21

tikalat wrote:- Experimenting with something called win32 shark_cheater (see ngemu forums - ePSxe_shark) (can't contact original author but seems free source) (modifying for possible relocatable RAM)

You can always use gamewizard32 with dosbox if that is what you are looking for.
User avatar
robertmo
l33t
 
Posts: 4160
Joined: 2003-6-18 @ 10:35

Re: Save States - Proof of concept

Postby Dominus » 2012-5-26 @ 15:06

is there one diff against current SVN of Dosbox? If I understand correctly it is against Yhkwongs which has countless other patches...
User avatar
Dominus
DOSBox Moderator
 
Posts: 7385
Joined: 2002-10-03 @ 09:54
Location: Vienna

Re: Save States - Proof of concept

Postby tikalat » 2012-5-26 @ 16:12

You can always use gamewizard32 with dosbox if that is what you are looking for.


Thanks! Must check this out. :)

Krondor ch4 is brutally hard. 1st dungeon and my team is already half-slaughtered.

is there one diff against current SVN of Dosbox? If I understand correctly it is against Yhkwongs which has countless other patches...


Unfortunately only diff is against ykhwong build.

If I can get svn to compile, I'll look it over,
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

Re: Save States - Proof of concept

Postby Dominus » 2012-5-26 @ 17:03

That would be great. I'd really like to give it a try on OSX and am not sure whether yhkwongs source will built without a hassle...
User avatar
Dominus
DOSBox Moderator
 
Posts: 7385
Joined: 2002-10-03 @ 09:54
Location: Vienna

Re: Save States - Proof of concept

Postby tikalat » 2012-5-26 @ 18:52

Code: Select all
005

render.cpp
+ Fix fps loadstate mistake


Code: Select all
001 - dosbox svn

Full POD support
- Only savestate support. Zero fixes added.


Test builds (dosbox + ykhwong)
http://www.sendspace.com/file/pkxgaz


Dosbox win32 build works okay here. Multi-diffs now attached.
(tested meaning various Krondor states load from CMOS okay)
You do not have the required permissions to view the files attached to this post.
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

Re: Save States - Proof of concept

Postby tikalat » 2012-5-27 @ 20:52

Code: Select all
svn-daum
006
+ add adlib POD (all versions)
+ use new mixer sub-POD ID enforcement (cut down on accidental loadstate crashes)

svn-dosbox
002 = same additions


Test build
http://www.sendspace.com/file/q25c3v


(Edit: fixing run-time crash error)
(Edit2: done fixing)
You do not have the required permissions to view the files attached to this post.
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

Re: Save States - Proof of concept

Postby Gamecollector » 2012-5-30 @ 19:03

Sometimes after the load state - the restored video mode is wrong. 720x576x8 in the place of 640x480x8, two black borders (right and bottom). Tested game - Supaplex.
The glitch isn't constant, from the same save the result may be wrong or right...
Asus P4P800 SE/Pentium4 3.2E/2 Gb DDR400B,
Radeon HD3850 Agp (Sapphire), Catalyst 14.4 (XpProSp3).
Voodoo2 12 MB SLI, Win2k drivers 1.02.00 (XpProSp3).
User avatar
Gamecollector
Oldbie
 
Posts: 1289
Joined: 2010-10-06 @ 22:17

Re: Save States - Proof of concept

Postby tikalat » 2012-5-30 @ 22:51

That's an odd bug. If the console is mentioning '720x576x8', it means the game attempted some type of resolution switch - there's a special case exception iirc though.

I'll check it out (currently absorbed by other projects). Does it happen at any place in the game (menus, in-game, loading, title)?


The svn-daum debugger window input doesn't work either but don't know why (svn-dosbox is okay).
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

Re: Save States - Proof of concept

Postby ykhwong » 2012-5-30 @ 23:16

tikalat wrote:The svn-daum debugger window input doesn't work either but don't know why (svn-dosbox is okay).


Sorry, the current svn-daum build of debugger is broken. (Alt-pause won't work for debugging) Please try 20120220 one which should work.
ykhwong
Oldbie
 
Posts: 627
Joined: 2004-3-17 @ 15:35

Re: Save States - Proof of concept

Postby robertmo » 2012-5-31 @ 01:50

ykhwong is there any place where we can post bugs about your builds?
can it be here viewtopic.php?t=9306
or you want to start a separate thread about your build only?
User avatar
robertmo
l33t
 
Posts: 4160
Joined: 2003-6-18 @ 10:35

Re: Save States - Proof of concept

Postby Gamecollector » 2012-5-31 @ 02:10

tikalat wrote:That's an odd bug. If the console is mentioning '720x576x8', it means the game attempted some type of resolution switch - there's a special case exception iirc though.

Your current build write the videomode info only after the video mode switch.
Loading of the savestate isn't considered as such switch.
So - just the "state 1 loaded!"
By the way, the glitch can be seen in the window mode too...
User avatar
Gamecollector
Oldbie
 
Posts: 1289
Joined: 2010-10-06 @ 22:17

Re: Save States - Proof of concept

Postby ykhwong » 2012-5-31 @ 02:15

robertmo wrote:ykhwong is there any place where we can post bugs about your builds?
can it be here viewtopic.php?t=9306
or you want to start a separate thread about your build only?

I understand that this is going off-topic. This thread must be about the development of save states, not specifically about a bug report of my builds.
Actually there's currently no place to post bugs on my website due to some server limitations. I couldn't afford it for a long time.
Either way is okay to me though my releases are not officially supported here by dosbox developers.
ykhwong
Oldbie
 
Posts: 627
Joined: 2004-3-17 @ 15:35

Re: Save States - Proof of concept

Postby laxdragon » 2012-5-31 @ 15:39

Perhaps you could consider hosting your branch on github. They offer a bug tracker and so on.

These days I prefer git for all my revision control needs.
User avatar
laxdragon
Member
 
Posts: 387
Joined: 2004-10-22 @ 18:42
Location: Minneapolis, MN

Re: Save States - Proof of concept

Postby tikalat » 2012-5-31 @ 21:19

Code: Select all
svn-daum 007
svn-dosbox 003


render.cpp / render.h
+ Add scrn_ratio to savestate
+ Fix loadstate problems with aspect ratio


Test build:
http://www.sendspace.com/file/h0yiti


NOTES:
This should fix the original + aspect ratio window size problems (use original screen ratio)
You do not have the required permissions to view the files attached to this post.
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

Re: Save States - Proof of concept

Postby Gamecollector » 2012-6-01 @ 07:44

Good. Supaplex wrong video mode is fixed.
Asus P4P800 SE/Pentium4 3.2E/2 Gb DDR400B,
Radeon HD3850 Agp (Sapphire), Catalyst 14.4 (XpProSp3).
Voodoo2 12 MB SLI, Win2k drivers 1.02.00 (XpProSp3).
User avatar
Gamecollector
Oldbie
 
Posts: 1289
Joined: 2010-10-06 @ 22:17

Re: Save States - Proof of concept

Postby tikalat » 2012-6-05 @ 23:11

Code: Select all
004  svn-dosbox

dos_files.cpp
+ add loadstate crash protection

cpu.cpp
+ use new cpu core switching idea


First one fixes a hang bug that happened with virtual files.

Second one lets you save using dynamic core. Exit. Switch to simple core. Reload state and continue (ex. debugger)


Test build:
(Removed per policy request)



NOTE:
I plan on creating a new thread for specifically ykhwong svn-daum support. Continuing the savestate + improvements over there.
You do not have the required permissions to view the files attached to this post.
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

ykhwong svn-daum - dosbox branch

Postby tikalat » 2012-6-08 @ 16:12

Continuing the save state improvements

Code: Select all
008

cpu.cpp
+ Use new loadstate idea (safely allows switching cores)

dos_files.cpp
+ Add safety check for loadstates (virtual files - CON, AUX, PRN)

glide.cpp
+ Add gulikoza's recent texture fix



Test build
http://www.sendspace.com/file/jcr07x
You do not have the required permissions to view the files attached to this post.
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

Re: Save States - Proof of concept

Postby tikalat » 2012-6-10 @ 22:44

Thanks to robertmo + Qbix for helping out. ;)

Super'ish patch.

Code: Select all
009
munt
+ Add mt32.partials conf line
(can change max partials from 32 -> 0-256)



010
vga.h
+ Amstrad video mode fix

innova.cpp / innova.h / reSID
+ Savestate POD (ex. Ultima 6)

3781-3782 svn fixes
+ IRQ0 (M.U.L.E), Mouse (Settlers 2)


tester


NOTE:
Actually have an idea for paging. Remove all existing vars. Create just skeleton shells and keep a list of them. Per module.

Then loadstate each one up and get the crazy amount of ptrs to line up.

TBD when I want to play around with Win 3.1 again.
You do not have the required permissions to view the files attached to this post.
tikalat
Member
 
Posts: 287
Joined: 2012-4-13 @ 16:39

PreviousNext

Return to DOSBox Patches

Who is online

Users browsing this forum: No registered users and 1 guest