Post subject: lsnes desync problem
Editor, Skilled player (1504)
Joined: 7/9/2010
Posts: 1317
Today my computer decided to shut down out of nowhere while I was TASing. I hadn't saved the movie and it desynced luckily near the end. I tried to fix the desync with savestates and backup savestates, which include the movie-file. Since the savestates include the movie file, the desync shouldn't be a problem anymore, but the desync is still there. Even if I loaded the a three days old backup movie (I hadn't TASed a few days), there's still a desync. Can someone help, for later desyncs? This one isn't a huge problem, I record the part again.
Favorite animal: STOCK Gt(ROSA)26Sortm1.1(rtTA,EGFP)Nagy Grm7Tg(SMN2)89Ahmb Smn1tm1Msd Tg(SMN2*delta7)4299Ahmb Tg(tetO-SMN2,-luc)#aAhmb/J YouTube Twitch
Post subject: Re: lsnes desync problem
Emulator Coder, Skilled player (1141)
Joined: 5/1/2010
Posts: 1217
TASeditor wrote:
Today my computer decided to shut down out of nowhere while I was TASing. I hadn't saved the movie and it desynced luckily near the end. I tried to fix the desync with savestates and backup savestates, which include the movie-file. Since the savestates include the movie file, the desync shouldn't be a problem anymore, but the desync is still there.
Bsnes core savestates aren't fully sync-stable. So even if one uses savestates correctly, it can still desync. The effect of each individual savestate is very small, but when lots of savestates are chained, desyncs can happen. Especially with games that seem to lag randomly. Also, some versions have busted movie code, but no recent version has one that is known to cause desyncs and still pass even remotely as working. Also, on Windows, lsnes savestates / movies aren't saved atomically (because I don't know how to write files atomically on Win32), but I think one could spot a damaged savestate pretty quickly (most probably those won't load, with variety of error messages depending on where exactly it blew).
Post subject: Re: lsnes desync problem
Joined: 2/13/2013
Posts: 2
Ilari wrote:
Bsnes core savestates aren't fully sync-stable. So even if one uses savestates correctly, it can still desync. The effect of each individual savestate is very small, but when lots of savestates are chained, desyncs can happen. Especially with games that seem to lag randomly.
Can you explain what exactly causes this to occur?
Post subject: Re: lsnes desync problem
Player (131)
Joined: 5/21/2012
Posts: 74
Location: Cary, NC
Ilari wrote:
Also, on Windows, lsnes savestates / movies aren't saved atomically (because I don't know how to write files atomically on Win32)
The "correct" way to do that is write it to a separate file and use ReplaceFile.
Post subject: Re: lsnes desync problem
RachelB
She/Her
Player (127)
Joined: 12/3/2011
Posts: 1579
hbalt wrote:
Ilari wrote:
Bsnes core savestates aren't fully sync-stable. So even if one uses savestates correctly, it can still desync. The effect of each individual savestate is very small, but when lots of savestates are chained, desyncs can happen. Especially with games that seem to lag randomly.
Can you explain what exactly causes this to occur?
Bad save state code.
Post subject: Re: lsnes desync problem
Emulator Coder, Skilled player (1141)
Joined: 5/1/2010
Posts: 1217
RachelB wrote:
hbalt wrote:
Can you explain what exactly causes this to occur?
Bad save state code.
Actually, the problem is bsnes internally using threading and thre way it brings threads to sync for saving.