BizHawk Emulator Development


creaothceann
He/Him
Editor, Experienced Forum User
Joined: 4/7/2005
Posts: 1874
Location: Germany
natt wrote:
creaothceann wrote:
Btw. a query:
RunToSave has never worked correctly over the entire life of bsnes. This was well known when the first bsnes movie was accepted to this site; if you pounded the savestate button a few dozen times at the beginning, the run would desync. Byuu has been presented facts about this a number of times and has flopped between viewpoints as needed, including denying the bugs, blaming them on the installation, and downplaying them as not significant for most users. The best example I can think of is Tales of Phantasia. It uses a uniquely difficult sound engine that crashes the emulated game and in some cases even the emulator when you savestate too many times. This is 100% repeatable on any Bizhawk build of the appropriate version: Turn on 1frame rewind, load the game, and watch the attract always crash on the exact same frame <6000 frames in (the exact number escapes me now...). I fixed the emulator crash https://github.com/TASVideos/BizHawk/commit/451f786660744835be868c7fca91ef3fc33db687 but the game still crashed; then I fixed the game crash https://github.com/TASVideos/BizHawk/commit/587270cad2ec96eaeec0ae60e4247c31a0a06a2e (note: there are two commits before it that are also relevant; see end). The exact problem was completely plain under a debugger, and once the fix was implemented it never happened again in Bizhawk, but according to Byuu that couldn't possibly have been it because the game works in Snes9x, which is much less accurate! Some other things are heavily broken too, all with the same MO: The game will work fine with no savestates, but the moment you start savestating every frame, things break. Super Game Boy, audio on some Rare games; Sonia knows more if you're interseted http://tasvideos.org/forum/viewtopic.php?t=19031 Besides complete breakage, there's also a lot of desync potential where a game will continue to run but handle timing subtlety differently. I believe Ilari has mitigated this by a combination of ignoring savestate requests at certain times and only taking savestates at known "good" times that happen to work out better, but I'm not sure; he's not the most cooperative and his code is impenetrable. Those solutions would be more duct tape and pray anyway; you still don't have something that is taking correct savestates. End: Here are all of the commits that I ripped out of bizhawk that were related to our coreside fixes for libco savestate problems: a60be7d2c9818229a0dcff0dbccf15f31015ca2a a7b6a9af4d4c049dbcd775f05f8539f86456e5e9 57b1df8487e3102b2e81c75fb96640cb1da430a4 9119e4f4ea7661b555125f8d6023efda8f6ed704 b2c0910376657208acb325953fbb2dbd4957d5e1 587270cad2ec96eaeec0ae60e4247c31a0a06a2e 74c26d9b117d3bdc78f5e5247909c9a05dee2a98 5e3d6555b02b1d6a6b61d8aeb3617e256697cd01 451f786660744835be868c7fca91ef3fc33db687 There might be more of them, and I know there are frontend commits as well, and many other issues that we just didn't solve.
byuu's reply: https://board.byuu.org/viewtopic.php?f=8&t=12&p=42176#p42176
Fortranm
He/Him
Editor, Experienced Forum User, Published Author (536)
Joined: 10/19/2013
Posts: 999
feos wrote:
You forgot updated GlideN64. And there's some work on recent mame too, which will hopefully make it to 1.x branch.
That's great to hear. Will MAME be an actual Bizhawk core or a part of the libretro core like how it is now?
Experienced Forum User, Published Author, Senior Judge, Senior Publisher (1423)
Joined: 4/17/2010
Posts: 10321
Location: RU
NES TAS of 2011
Fortranm wrote:
feos wrote:
You forgot updated GlideN64. And there's some work on recent mame too, which will hopefully make it to 1.x branch.
That's great to hear. Will MAME be an actual Bizhawk core or a part of the libretro core like how it is now?
There are 3 options. - Make it work only through libretro, fixing both mame core and libretro to rerecord properly. - Port mame core directly or its libretro interface like a usual bizhawk core. - Waterbox mame in its entirety. The last option can't be done without splitting mame into single driver parts, otherwise each game would have insane overhead in its savestates. The second option requires fist fixing everything and wiring it all up. The first option is supposed to fix everything and wire it up, and make it possible to port mame directly if needed, and it also helps to fix other libretro cores. So I'm working on the first option.
Warning: When making decisions, I try to collect as much data as possible before actually deciding. I try to abstract away and see the principles behind real world events and people's opinions. I try to generalize them and turn into something clear and reusable. I hate depending on unpredictable and having to make lottery guesses. Any problem can be solved by systems thinking and acting. If TASing is meta-play, TASVideos Movie Rules are meta-meta-play!
Editor, Emulator Coder, Experienced Forum User, Site Developer
Joined: 5/11/2011
Posts: 1105
Location: Murka
creaothceann wrote:
byuu's reply: https://board.byuu.org/viewtopic.php?f=8&t=12&p=42176#p42176
I honestly didn't write that for Byuu's benefit, just the benefit of other people that might be interested. As for his reply, I didn't read past the "it's possible" in the first sentence. We've got years of experience from many TASers and multiple developers working on this core to demonstrate these facts. Byuu is like a climate change denier but for emulation determinism.
Sonia
She/Her
Experienced Forum User
Joined: 12/6/2013
Posts: 428
Location: Brazil
So, I've been messing around with the rewind function in 1.13.0 and noticed it doesn't work for all cores. Below are the ones I tested: Works -NES -Genesis -PC Engine -SMS -Game Gear -GB and GBC -WonderSwan and WSC (Judgement Silversword failed) Doesn't Work -SNES -Sega CD -PCECD -N64 -PS1 -GBA Will we be able to rewind those cores in the upcoming Bizhawk 2.0?
feos wrote:
There are 3 options. - Make it work only through libretro, fixing both mame core and libretro to rerecord properly. - Port mame core directly or its libretro interface like a usual bizhawk core. - Waterbox mame in its entirety. The last option can't be done without splitting mame into single driver parts, otherwise each game would have insane overhead in its savestates. The second option requires fist fixing everything and wiring it all up. The first option is supposed to fix everything and wire it up, and make it possible to port mame directly if needed, and it also helps to fix other libretro cores. So I'm working on the first option.
I was hoping for the 3rd option myself, as I've always dreamed about having MAME in the regular bizhawk to keep all my movies organized in the same place. I've never used libretro before and know very little about it, other than I pretty often see it talked about on emulation sites. But either way, do what you think is best.
adelikat
He/Him
Emulator Coder, Published Author, Site Admin (4250)
Joined: 11/3/2004
Posts: 4656
Location: Tennessee
TASer of 2010NES TASer of 2010DS TASer of 2010Arcade TAS of 2010NES TASer of 2008NES TAS of 2008Funny TAS of 2008TASer of 2007NES TASer of 2007Funny TAS of 2007
Sonia wrote:
So, I've been messing around with the rewind function in 1.13.0 and noticed it doesn't work for all cores. Below are the ones I tested: Works -NES -Genesis -PC Engine -SMS -Game Gear -GB and GBC -WonderSwan and WSC (Judgement Silversword failed) Doesn't Work -SNES -Sega CD -PCECD -N64 -PS1 -GBA
Config -> Rewind & States Notice by default rewind is off on cores with larger savestates. This is because there is a performance cost. Turn it on for cores you want and fiddle with settings. Rewind works for all cores. You are just reporting what the default options are here.
Pimpin' ain't easy My Homepage My TAS projects
Experienced Forum User, Published Author, Senior Judge, Senior Publisher (1423)
Joined: 4/17/2010
Posts: 10321
Location: RU
NES TAS of 2011
Sonia wrote:
I was hoping for the 3rd option myself, as I've always dreamed about having MAME in the regular bizhawk to keep all my movies organized in the same place. I've never used libretro before and know very little about it, other than I pretty often see it talked about on emulation sites.
We have a libretro launcher. This is what I mean, bizhawk's libretro later for mame, not retroarch.
Warning: When making decisions, I try to collect as much data as possible before actually deciding. I try to abstract away and see the principles behind real world events and people's opinions. I try to generalize them and turn into something clear and reusable. I hate depending on unpredictable and having to make lottery guesses. Any problem can be solved by systems thinking and acting. If TASing is meta-play, TASVideos Movie Rules are meta-meta-play!
Experienced Forum User
Joined: 12/1/2016
Posts: 12
Will 3D Pad support be available with the update to the Saturn core as well? I'd like to be able to have that for a couple of games I'd like to experiment a TAS with.
Editor, Emulator Coder, Experienced Forum User, Site Developer
Joined: 5/11/2011
Posts: 1105
Location: Murka
Shentok wrote:
Will 3D Pad support be available with the update to the Saturn core as well? I'd like to be able to have that for a couple of games I'd like to experiment a TAS with.
Yes
Experienced Forum User
Joined: 12/1/2016
Posts: 12
natt wrote:
Shentok wrote:
Will 3D Pad support be available with the update to the Saturn core as well? I'd like to be able to have that for a couple of games I'd like to experiment a TAS with.
Yes
Awesome. Thank you very much. I will look forward to this release. The updated core will really help with Saturn TASing.
Sonia
She/Her
Experienced Forum User
Joined: 12/6/2013
Posts: 428
Location: Brazil
adelikat wrote:
Config -> Rewind & States Notice by default rewind is off on cores with larger savestates. This is because there is a performance cost. Turn it on for cores you want and fiddle with settings. Rewind works for all cores. You are just reporting what the default options are here.
Thanks a million. Simply checking the boxes for "Medium savestates" and "Large savestates" did the trick. By the way, is it possible to rewind toggle instead of having to hold it down? An unrelated thing I forgot to mention:
adelikat wrote:
* SNES - Snes9x 1.54 ported. Note that bsnes still should be used for serious TASing intended for submission at TASVideos. But snes9x is provided for its performance and decent compatibility for casual gaming, botting, and testing
I'd suggest porting 1.53 instead. Main reason is that 1.54 wrecked the audio of some games. Haisei Mahjong - Ryouga, Dark Law - Meaning of Death, Super Pinball - Behind the Mask, to name a few. There's now a heavy and painful audio screeching that didn't exist in 1.53. The reason is that they changed the SMP to the one written by byuu for bsnes performance. The same bugs exist in bsnes' performance core if you run those games there.
Experienced Forum User, Published Author, Senior Judge, Senior Publisher (1423)
Joined: 4/17/2010
Posts: 10321
Location: RU
NES TAS of 2011
Sonia wrote:
The reason is that they changed the SMP to the one written by byuu for bsnes performance. The same bugs exist in bsnes' performance core if you run those games there.
This is so absurd that it's hilarious.
Warning: When making decisions, I try to collect as much data as possible before actually deciding. I try to abstract away and see the principles behind real world events and people's opinions. I try to generalize them and turn into something clear and reusable. I hate depending on unpredictable and having to make lottery guesses. Any problem can be solved by systems thinking and acting. If TASing is meta-play, TASVideos Movie Rules are meta-meta-play!
Sonia
She/Her
Experienced Forum User
Joined: 12/6/2013
Posts: 428
Location: Brazil
feos wrote:
This is so absurd that it's hilarious.
What do you mean by "this"? bsnes performance being buggy or my statement? If you mean the former, then all right. But if you're skeptical over my statement, then just run the three games I mentioned in snes9x 1.54 and bsnes performance/compatibility/accuracy. You'll notice that the bugs only exist in 1.54 and bsnes performance (and by extension, bizhawk's snes performance core), since they all share the same SMP code. 1.53 and bsnes compatibility/accuracy runs them perfectly.
Pokota
He/Him
Experienced Forum User
Joined: 2/5/2014
Posts: 776
Compared to console?
Adventures in Lua When did I get a vest?
Sonia
She/Her
Experienced Forum User
Joined: 12/6/2013
Posts: 428
Location: Brazil
Yes. Here, I made an audio comparison video: https://www.youtube.com/watch?v=v1OwD6vUhiQ Here is the order I went through things: -Dark Law (higan balanced -> snes9x 1.53 -> higan performance -> snes9x 1.54) -Haisei Mahjong (higan balanced -> snes9x 1.53 -> higan performance -> snes9x 1.54) -Super Pinball (higan balanced -> snes9x 1.53 -> higan performance -> snes9x 1.54) As it can be seen, audio is completely wrecked in performance/1.54. But it works correctly in balanced/1.53.
Experienced Forum User, Published Author (442)
Joined: 12/13/2016
Posts: 348
Minor initial config suggestion that I think people would find useful: change default key for select from spacebar to backspace it's what most people use, and signficantly reduces n-key rollout with combinations of select and other buttons (in particular, soft resets).
Experienced Forum User, Published Author, Senior Judge, Senior Publisher (1423)
Joined: 4/17/2010
Posts: 10321
Location: RU
NES TAS of 2011
Sonia wrote:
What do you mean by "this"? bsnes performance being buggy or my statement?
The situation. Performance profile gets dropped due to being useless for casual play when snes9x is here, and after all the drama about byuu's decisions and moving away from them in terms of savestates, they hit us from the back, from snes9x itself, where they were reused. And they are exactly what causes bugs there. And 1.54 has already been integrated. Fucking LOL.
Warning: When making decisions, I try to collect as much data as possible before actually deciding. I try to abstract away and see the principles behind real world events and people's opinions. I try to generalize them and turn into something clear and reusable. I hate depending on unpredictable and having to make lottery guesses. Any problem can be solved by systems thinking and acting. If TASing is meta-play, TASVideos Movie Rules are meta-meta-play!
Editor, Emulator Coder, Experienced Forum User, Site Developer
Joined: 5/11/2011
Posts: 1105
Location: Murka
I remember byuu ranting back in the day about snes9x developers copying bits of bsnes without looking at the big picture of emulation accuracy, and so accomplishing nothing... I guess they didn't learn their lesson. The good news for bizhawk is that bsnes compat core is faster than it was and the determinism issues are gone, so snes9x isn't actually that important to us.
Post subject: BizHawk 2.0 released
adelikat
He/Him
Emulator Coder, Published Author, Site Admin (4250)
Joined: 11/3/2004
Posts: 4656
Location: Tennessee
TASer of 2010NES TASer of 2010DS TASer of 2010Arcade TAS of 2010NES TASer of 2008NES TAS of 2008Funny TAS of 2008TASer of 2007NES TASer of 2007Funny TAS of 2007
Two releases today! BizHawk 2.0 finally released. If you have been following the thread you know what's up. Be sure to run the new prereq installer. BizHawk 1.13.1 also released, for those on pre-Windows 7 OSes. Be sure to read the Release notes for more details.
Pimpin' ain't easy My Homepage My TAS projects
adelikat
He/Him
Emulator Coder, Published Author, Site Admin (4250)
Joined: 11/3/2004
Posts: 4656
Location: Tennessee
TASer of 2010NES TASer of 2010DS TASer of 2010Arcade TAS of 2010NES TASer of 2008NES TAS of 2008Funny TAS of 2008TASer of 2007NES TASer of 2007Funny TAS of 2007
Note one known bug: the Neo-Geo pocket core was unintentionally classified as not released. It is released though. If will nag you if you try to record a movie but just click ok and ignore it.
Pimpin' ain't easy My Homepage My TAS projects
Alyosha
He/Him
Editor, Experienced Forum User, Published Author (3927)
Joined: 11/30/2014
Posts: 2388
Location: US
NES TASer of 2015
Hurray 2.0 is here! Great work to everyone who helped get the new cores working and especially natt who made some seriously huge commits and got the magical water boxing stuff working. This is a big advancement in TASing technology ! Now we just need a TASVideos 2.0 :)
PikachuMan
He/Him
Experienced Forum User, Limited User, Published Author (14)
Joined: 9/12/2009
Posts: 1510
Location: Wichita
On BizHawk, If you get an error message that reads "Windows cannot access the specified device, path, or file. You may not have the appropriate permissions to access the item" check your antivirus and add BizHawk 2.0 to the exclusions/exceptions/whitelist and the game mode.
A Gameboy saveram splitter/combiner tool will be very useful for the 1st gen and 2nd gen Pokémon games.
Experienced Forum User
Joined: 9/12/2014
Posts: 502
Location: Waterford, MI
I don't understand this whole "waterbox" technique.. Does it mean it will make it easier to port cores from this: http://buildbot.libretro.com/nightly/windows/x86_64/latest/ ? If so, that will be awesome!
Challenger
He/Him
Experienced Forum User, Published Author (2752)
Joined: 2/23/2016
Posts: 916
Sega TASer of 2017TASer of 2017NES TAS of 2017
Excellent work with the newest version and new cores! Also, any plans to add 32X someday?
My homepage --Currently not much motived for TASing as before...-- But I'm still working.
Editor, Emulator Coder, Experienced Forum User, Site Developer
Joined: 5/11/2011
Posts: 1105
Location: Murka
InfamousKnight wrote:
I don't understand this whole "waterbox" technique.. Does it mean it will make it easier to port cores from this: http://buildbot.libretro.com/nightly/windows/x86_64/latest/ ? If so, that will be awesome!
In short, it's a way for cores to make better savestates. It could be used for more libretro cores, but it doesn't make things automatic.