From b470fa5454088effae64377f147db3e213947cd0 Mon Sep 17 00:00:00 2001 From: JosJuice Date: Sun, 12 Feb 2017 13:02:57 +0100 Subject: FileMonitor redesign Advantages: * Simpler code in general * No extra volume objects created * Now actually notices if the disc or partition gets changed while the core is running * No longer picks up on disc access done by the GUI (it used to do so as long as the core was running) * Gets rid of a Core dependency in DiscIO There are two performance disadvantages: * FileMonitor is now a bit slower when used with VolumeDirectory because FileMonitor now always uses the FileSystemGCWii code for finding filenames instead of VolumeDirectory finding the filename on its own and directly hooking into FileMonitor. But this isn't such a big deal, because it's happening on the DVD thread, and my currently unmerged file system PR will make FileSystemGCWii's file finding code about as fast as VolumeDirectory's. * FileMonitor's creation of the file system object is now done on the CPU thread instead of the DVD thread, and it will be done even if FileMonitor logging is disabled. This will be fixed in the next commit. --- Source/Core/DiscIO/VolumeGC.cpp | 3 --- 1 file changed, 3 deletions(-) (limited to 'Source/Core/DiscIO/VolumeGC.cpp') diff --git a/Source/Core/DiscIO/VolumeGC.cpp b/Source/Core/DiscIO/VolumeGC.cpp index 60b9846504..0f302b5ce0 100644 --- a/Source/Core/DiscIO/VolumeGC.cpp +++ b/Source/Core/DiscIO/VolumeGC.cpp @@ -17,7 +17,6 @@ #include "Common/StringUtil.h" #include "DiscIO/Blob.h" #include "DiscIO/Enums.h" -#include "DiscIO/FileMonitor.h" #include "DiscIO/Filesystem.h" #include "DiscIO/Volume.h" #include "DiscIO/VolumeGC.h" @@ -38,8 +37,6 @@ bool CVolumeGC::Read(u64 _Offset, u64 _Length, u8* _pBuffer, bool decrypt) const if (decrypt) PanicAlertT("Tried to decrypt data from a non-Wii volume"); - FileMon::FindFilename(_Offset); - return m_pReader->Read(_Offset, _Length, _pBuffer); } -- cgit v1.2.3