The single greatest mission of an emulator is the preservation of a console and its games. The Dolphin team has made a commitment to that, especially over the past two years. After nearly a decade of guesswork, hacks, and "good enough" emulation, the developers took a stand to strive for something greater. This change in goals has forced difficult decisions had to be made again and again.
This past month has been one filled with the benefits of working with an accuracy oriented mindset. Not only were there tons of fixes for popular games, but with those fixes also came increases to performance for those who wish to enjoy the Dolphin experience. This is why we keep trudging toward true accurate emulation, even when it means leaving some things behind.
4.0-1503 - New PPC Analyst Class by Sonicadvance1¶
Whenever there are changes to the Just In Time compiler (JIT), close attention needs to be paid. Performance and accuracy both greatly depend on CPU emulation working properly. This change rewrites the analyst so that more instructions can be processed in less time. How much does this affect CPU core performance? Quite a bit!
Unfortunately, most games see a smaller boost. The main exception to this are the Nintendo 64 Virtual Console games, which see this improvement in full force!
4.0-1525 - Fix indirect texture coordinate computation by magumagu¶
This nasty little bug actually affects hundreds of games. Unfortunately, most users would probably never think to try these games. That's right, this is a merge that primarily affects NES Virtual Console games. This merge fixes tons of sprite errors in every single NES Virtual Console game, most GameCube emulated NES games, as well as some Wii re-releases of older games. Users can now enjoy NES games in all their 8-bit glory from within Dolphin.
So what was Dolphin doing wrong? It turns out it wasn't computing the coordinates correctly for textures using indirect texturing. Pretty self explanatory to the name of the merge, in this case.
Fixed issues 7092
4.0-1533 - XFB Width/Height Handling Fixes by magumagu¶
Real External Frame Buffer (RealXFB) is supposed to be the most accurate form of external frame buffer in Dolphin. Unfortunately in many games, including Animal Crossing, RealXFB was completely unusable due to severe graphical glitches. With these fixes merged, RealXFB is closer to perfect emulation.
Keeping with the Virtual Console theme; it's actually the popular GameCube port of Ocarina of Time, featuring the Master Quest version.
4.0-1592 - Make DVD Seek Timing More Accurate by magumagu¶
Why emulate loading times? That is a question that many users and developers have posed over the years. A difficult task that brings most users (outside of a small subset) no benefit and may even be unwanted by many.
To make matters more tenuous, research shows that various Wii/GameCube disc drives can differ substantially. The faster the console's disc drive is, the faster the load times can get. That means emulating an infinitely fast disc drive was easily defensible.
Unfortunately, this quirk also changed the behavior in games that dynamically load assets. An excellent examples of this is Metroid Prime where many of the tricks and glitches that work on console, didn't work on emulator due to rooms loading so fast that you cannot get back in bounds. With the new code in place, Tool Assisted Speedrunner Cafde of TASVideos demonstrates Early Ice Beam finally working in Dolphin, just as it would on console.
For those who don't want load times? The "Speed up Disc Transfer Rate" option in the game properties menu will disable this functionality.
Fixed issue 5431
4.0-1694 - JIT Optimize Instruction Cache Invalidation by kayru¶
Sometimes a merge will do multiple, unrelated things. In this case, some code was rearranged to make Visual Studio compile code more cleanly. But, more importantly, it also made clearing the instruction cache in the JIT a much less strenuous task. Prior to this build, the instruction cache was being manually set to invalid for sanitation purposes. In modern Dolphin, this turned out to be entirely unnecessary as it was being cleared anyway. What does this mean for the users? Well, CPU limited games should see an average of about 3 - 10% increase in performance as of this build! For example, the areas hit hardest by the old cache invalidation in Metal Gear Solid: The Twin Snakes can be up to 25% faster.
4.0-1706 - Fix frsqrte and fres by magumagu¶
Despite already making several really big accuracy changes, magumagu returns to the list again with two huge fixes. One of the jobs of the emulator is to play the games as they played on the target console. As such, one of the most frustrating things about emulation is when a childhood favorite doesn't play just as remembered. That worst case scenario had been plaguing Dolphin, with popular games such as Mario Kart: Double Dash suffered from the complete inability to accelerate properly while turning!
But it wasn't just Mario Kart: Double Dash; Super Mario Galaxy, Super Mario Sunshine, The Legend of Zelda: Twilight Princess, Resident Evil 4, Mario Party 6, 7 and many others all had significant issues. It wasn't just physics errors, this problem could result in impossible to complete levels all the way to completely broken graphics.
So what was causing all these calamities? Well, in one of the interpreter functions deep within Dolphin's CPU core, it turns out some of the instructions were being calculated too precisely of all things. In particular, estimation instructions frsqrte and fres were the culprits. By making Dolphin answer exactly as the console, tons of problems simply vanished.
Fixed issues 4576, 4684, 6096, 6100, 6888, 7014, 7153, 7158, 7292 and likely others.
Special Thanks to the committers...¶
delroth, Sonicadvance1, tilka, SeannyM, magumagu, degasus, shuffle2, Jezze, LPFaint99, lioncash, linktothepast, RachelBryk, neobrain, jordan-woyak, myownfriend, magcius, kayru and CarlKenner for incrementing Dolphin 4.0-1492 through to 4.0-1759!
Behind the Scenes Sneak Peek: Dolphin GameCube GBA Link Communication.¶
Though still a very early prototype, a rewrite of the GameCube GBA Link emulation is underway featuring Higan and it's relatively young GBA core. Considering all the issues around this kind of support, it's amazing to think that shuffle2 has already gotten more than twice as many games working than were previously supported through linking to VBA-M! A short video demonstration shows off some of the games that are already somewhat working.
Issue Tracker Gold¶
A month cannot be complete without at least one baffling issue report. This time, a user brought to our attention issue 7292 from the very popular game Mario Party 6. What kind of bug could have been missed for so long in such a popular game? How about a game breaking bug that completely locks off one of the modes from conventional use. What happens, well, let's take a look and see!
During the construction of this article The Dolphin Team is proud to announce that this issue has already been bopped. The same build also fixed last months Issue Tracker Gold; so, how about that? Regardless, enjoy the now defunct bug in Mario Party 6!