GovanifY / bizhawk

Automatically exported from code.google.com/p/bizhawk
0 stars 0 forks source link

Firmware path crashes #307

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Give the firmware path a directory with a large number of files
2. Try to access the firmware manager or open a ROM requiring firmware

What is the expected output? What do you see instead?
Memory usage builds up very quickly until:
    When opening the firmware manager:
        ************** Exception Text **************
    System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.
       at BizHawk.Client.Common.FirmwareManager.RealFirmwareReader.Read(FileInfo fi)
       at BizHawk.Client.Common.FirmwareManager.DoScanAndResolve()
       at BizHawk.Client.EmuHawk.FirmwaresConfig.DoScan()
       at BizHawk.Client.EmuHawk.FirmwaresConfig.RefreshBasePath()
       at BizHawk.Client.EmuHawk.FirmwaresConfig.FirmwaresConfig_Load(Object sender, EventArgs e)
       at System.Windows.Forms.Form.OnLoad(EventArgs e)
       at System.Windows.Forms.Form.OnCreateControl()
       at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
       at System.Windows.Forms.Control.CreateControl()
       at System.Windows.Forms.Control.WmShowWindow(Message& m)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
       at System.Windows.Forms.ContainerControl.WndProc(Message& m)
       at System.Windows.Forms.Form.WmShowWindow(Message& m)
       at System.Windows.Forms.Form.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

    When opening a GBA ROM:
    System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown. at System.RuntimMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) at System.Reflection.RuntimConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) at BizHawk.Emulation.Cores.CoreInventory.Core.Create(CoreComm comm, GameInfo game, Byte[] rom, Byte[] file, Boolean deterministic, Object settings, Object syncsettings) at BizHawk.Client.Common.RomLoader.LoadRom(String path, CoreComm nextComm, Boolean forceAccurateCore)

What version of the product are you using? On what operating system?
v1.8.4, Windows 8.1

Original issue reported on code.google.com by gcupcakekid on 11 Nov 2014 at 3:58

GoogleCodeExporter commented 9 years ago
we cant fix memory leaks, we can only try to suppress them.
I tried to suppress it in r8166 and probably succeeded.

Original comment by zero...@zeromus.org on 12 Nov 2014 at 12:05

GoogleCodeExporter commented 9 years ago
user has 572MB file in firmware directory. user shouldnt do this. needs support 
by streaming the hash calculations. maximum lowest priority.

Original comment by zero...@zeromus.org on 12 Nov 2014 at 1:12

GoogleCodeExporter commented 9 years ago
streaming hash implemented. further suggestion to only check for known 
filesizes should accelerate matters substantially.

Original comment by zero...@zeromus.org on 12 Nov 2014 at 1:54

GoogleCodeExporter commented 9 years ago
Fixed, revision 8171

Original comment by adeli...@tasvideos.org on 13 Nov 2014 at 11:41

GoogleCodeExporter commented 9 years ago

Original comment by adeli...@tasvideos.org on 13 Nov 2014 at 11:41