Project

General

Profile

Actions

Emulator Issues #6829

closed

Wii titles using .vff files to store content become unresponsible until the file is created

Added by mbc07 over 10 years ago.

Status:
Fixed
Priority:
Normal
Assignee:
-
% Done:

0%

Operating system:
N/A
Issue type:
Bug
Milestone:
Regression:
No
Relates to usability:
No
Relates to performance:
No
Easy:
No
Relates to maintainability:
No
Regression start:
Fixed in:

Description

Titles?
Super Smash Bros Brawl (RSBE01), Wii Menu (any version), Opera Internet Channel (any version), Wii Shop Channel (any version)

What went wrong?
The titles mentioned above uses VFF files to store data. When running the title for the first time, the .vff files will be created, however, the emulation will be veeeery slow (FPS 0-2/VPS 0-2) while the file is being populated, and it may take around 2 to 5 minutes, depending of the title. In fact, the emulation seems to be frozen, but waiting patiently gives the speed back.

It's most noticeable when creating a new save file for Super Smash Bros Brawl (it creates a collect.vff file around 16MB) or when booting Wii Menu for the first time (it creates a cdb.vff file around 20MB), but the same apply with Opera Internet Channel and Wii Shop Channel. It's less noticeable because the .vff files created by these two are very small..

What did you expect to happen instead?
It appears that the code responsible for handling the .vff creation isn't asynchronous, to, the emulation will be severely slow until the file is created. The titles shouldn't get slowed down while creating the file, like a real Wii does.

What steps will reproduce the problem?
It's important that you use an empty folder as Wii NAND root to be able to reproduce this. After that, just boot the channel WAD or ask Super Smash Bros Brawl to create a new save file.

Which versions of Dolphin did you test on?
All stable releases (2.0, 3.0, 3.5 and 4.0.1) and the latest master branch build, all of them x64

Which version of Dolphin used to work?
As far as I tested, none of them work. Some builds have a small piece of code to create the .vff file instantly, but it works only with Wii Menu, the other titles still have the issue.

What are your PC specifications?
CPU: Intel Core i7 3630QM @ 2.4GHz (3.4GHz Turbo Boost)
GPU: nVidia GeForce GT635M @ 2GB GDDR3 RAM
OS: Windows 8 x64
RAM: 8 GB

Operating System?
Windows 8 x64

Any other relevant information?
There is code for creating .vff files in the emulator, and it seems to be used only in Wii Menu. I know that this code were reverted and reimplemented sometimes while ago, and perhaps it could be reused as a possible workaround.

More information about .vff files are available at WiiBrew: http://www.wiibrew.org/wiki/VFF

Actions #1

Updated by comexk over 10 years ago

Has anyone figured out why the VFF creation algorithm runs so poorly in Dolphin?

Actions #2

Updated by mbc07 over 10 years ago

Dolphin has the HLE_IPC_CreateVirtualFATFilesystem() function in WII_IPC_HLE_Device_FileIO.cpp, maybe it could be reused as a workaround in the meantime?

Actions #3

Updated by skidau over 10 years ago

comexk, it is just as slow on the real hardware too. Running Dolphin on a SSD would make this process faster.

Actions #4

Updated by mbc07 over 10 years ago

...but on real hardware the game/channel doesn't become super slow (FPS0-2) while the file is being populated

Actions #5

Updated by skidau over 10 years ago

It would if the Wii used a hdd for the nand.

Actions #6

Updated by mbc07 over 10 years ago

WOW, if it's the case, this issue is invalid =(

How feasible would be using the HLE_IPC_CreateVirtualFATFilesystem() function for this whenever a game/channel tries to create a .vff file (although this would just increase the number of hacks present in the emu)?

Actions #7

Updated by tueidj over 10 years ago

I ran into a similar issue when writing the save directory redirection for Riivolution, the fix I used was to gather consecutive individual writes (which are always 512 bytes each, this is the main cause of the slowdown) in a 16384 byte buffer and flush it to disk when full.

Actions #8

Updated by JMC4789 over 10 years ago

I've been running Dolphin on a solid state and can say that I've never run into this hanging thing on the solid state. I need to try it on my regular harddrive sometime...

Actions #9

Updated by parlane about 10 years ago

  • Status changed from New to New
Actions #10

Updated by mbc07 about 10 years ago

Found something: in the same computer, I get this issue in Windows, but in Ubuntu not. Maybe an I/O problem with some Windows specific driver?

Actions #11

Updated by JMC4789 almost 9 years ago

  • Status changed from New to Fix pending
Actions #12

Updated by phire almost 9 years ago

I get this issue in Windows, but in Ubuntu not. Maybe an I/O problem with some Windows specific driver?

Antivirus.

Nobody ever has antivirus running on non windows systems.

Actions #13

Updated by mbc07 almost 9 years ago

Fixed in 4.0-6970...

Actions #14

Updated by JosJuice almost 9 years ago

  • Status changed from Fix pending to Fixed
Actions

Also available in: Atom PDF