Emulator Issues #4413
closedDX11 stability regressions since r7421 (perhaps NVIDIA-only) - occasionnal crashes on stop, video memory corruption on second(+) runs?
Added by SAMuhammed over 13 years ago.
0%
Description
On exit from Dolphin after playing few GC & Wii games Dolphin.exe stops working. If close button pressed it displays Dolphin.exe stops working for the second time. Pressing close button quits Dolphin without any error message.
Dolphin version: r7473 (I didn't try with other svn)
Dolphin version that does not have the problem: r6926
Operating system and version: Windows 7 32-bit /GPU HD5670
Game ID: GKJE78 (Disney/Pixar presents Cars); RPBP01 (Pokemon Battle Revolution)
Games are in ISO format.
Additional information:
This happens only with DX11. Same games do not exhibit this error with DX9.
If Debug button pressed it displays
Unhandled exception at 0x0032df4b in Dolphin.exe: 0xC0000005: Access violation reading location 0x62303540.
Call Stack pointing
> Dolphin.exe!DX11::SharedPtr<ID3D11PixelShader>::~SharedPtr<ID3D11PixelShader>() Line 61 + 0x8 bytes C++
Updated by peppyhare604 over 13 years ago
I got a crash on exit also, from selecting exit from the Dolphin menu.
When debugging with Visual Studio 2010 the popup says:
Unhandled exception at 0x000007fefdb49670 in Dolphin.exe: 0xC0000005: Access violation writing location 0x0000000000200fe8.
and it shows me a green arrow pointed at line 132 of MemTools.cpp which reads:
return EXCEPTION_CONTINUE_SEARCH;
Updated by NeoBrainX over 13 years ago
Yeah ... smart pointers solve all our memory leaks, right...
Especially since D3D11 had that many.[/cynicism]
Updated by NeoBrainX over 13 years ago
Fwiw, not sure what's going on. Guess it's a regression caused by replacing all COM refcounting by smart pointers in the D3D11 code.
Updated by SAMuhammed over 13 years ago
This problem starts from Dolphin version 7421 and onward.
Updated by irencepn over 13 years ago
Nice info SAM, i didnt know in which rev problem appeared exactly.
Updated by wespipes69 over 13 years ago
I would deem this a 3.0 blocker personally - ugly regression that will affect a lot of users.
Updated by NeoBrainX over 13 years ago
Does this happen for other games as well?
Updated by wespipes69 over 13 years ago
Happens on all games in my experience. Upon starting a game, stopping it and exiting emu, I get the error message about 90% of the time.
Updated by SAMuhammed over 13 years ago
I've noticed, If I play any game after playing one of those games (Disney/Pixar presents Cars or Pokemon Battle Revolution, some more..) and then exit, Dolphine.exe stops working.
Updated by EmanModnar over 13 years ago
I did some investigating, and it seems to be something with CMPR format textures. I've tested with PoP:T2T, which uses CMPR textures right away, and the crash always occurs with it, while Soul Calibur II doesn't use them until you see a character model and won't cause the crash if closed prior to the Select Character screen.
Updated by EmanModnar over 13 years ago
Correction: Soul Calibur II doesn't use the CMPR Textures until a match starts.
Updated by irencepn over 13 years ago
I think you have right. Dolphin doesent crash if you interrupt SC2 before a fight, then exit dolphin.
Updated by DimitriPilot3 over 13 years ago
- Category set to gfx
- Issue type set to Bug
Has anyone encountered, using DX11 and without closing Dolphin, apparent video memory corruption and/or video driver crashes while running SSBB for the second and subsequent times? (especially noticeable with the 2D characters that appear right before the intro movie, the title screen, the menues...)
I am using a NVIDIA GeForce 8800 GTS 512 graphics card and the 260.99 NVIDIA drivers.
I'd like to elaborate a bit more, but don't really have time to do so now...
Updated by DimitriPilot3 over 13 years ago
First interesting note:
I believe the video memory corruption isn't restricted in Dolphin, as it can corrupt the GFX memory of other 3D applications such as TrackMania United Forever.
Updated by SAMuhammed over 13 years ago
I don't have SSBB or TMUF, but I've played many games more than once in a single session using DX11. I haven’t experienced any graphic corruption in Dolphin or in a PC game after using Dolphin.
I'm using ATI HD5670.
Updated by DimitriPilot3 over 13 years ago
- Priority set to High
I am quite sure that my problems started with r7421 (still reproducible using the NVIDIA 267.24 drivers on Windows 7 x86), as I didn't experience those weird graphical corruptions using Mamario's build of r7420, nor the random crashing on stop, nor the video driver crashes...
Example screenshots of randomly corrupted stuff: http://www.mediafire.com/?vqpn6sz2q8pw9
I wonder if this is an issue which truly only shows its effects (crash on stop, video RAM corruption, possible video driver crashes, and Dolphin hangs (especially in-game or in character selection menu)) with NVIDIA drivers and not ATI drivers...
Maybe or a bug in Dolphin that corrupts pointers/memory in a way that causes NVIDIA shaders to do evil stuff? I dunno...
Is there a way to debug this other than trying to revert parts of r7421 (with compilation fixes, obviously) until it works? At least, reverting the GfxState changes didn't seem to fix this...
Updated by NeoBrainX over 13 years ago
Fwiw, I'm already working on reverting r7421.
Updated by NeoBrainX over 13 years ago
Although you're free to do it yourself as well (since I'm short of time these days) :P
fwiw, you should probably remove the whole SharedPtr stuff (rather than only parts of it), it was stupid to begin with anyway IMO.
Updated by tommyhl2.SS over 13 years ago
I can't get dx11 to crash on stop here. HD3650 - DX 10.1.
Updated by ExtremeDude2 over 13 years ago
@tommy
That is because they think it only effects NVIDIA.
Updated by NeoBrainX over 13 years ago
Anyone with the problem, please check r7592.
Updated by NeoBrainX over 13 years ago
- Status changed from New to Fixed
Fixed by reverting r7421 in r7592.
Updated by DimitriPilot3 over 13 years ago
I can confirm it too.
For the record, the problem looked like it was due to some erroneous reference counting done by SharedPtr on some resources (such as ID3D11DepthStencilState, ID3D11BlendState, and ID3D11RasterizerState, as reported by the DX11 debug libraries during SetPrivateData() calls).
Now what if the "video memory corruption" was caused by some buggy API's (NVIDIA's?) free'ing data based on obsoleted pointers? But whatever :p
Updated by NeoBrainX over 13 years ago
It most likely was caused by that, and it would have been trivial to find out by just checking the output of the D3D11 debug layer (which would've even told us WHICH device object didn't get released properly).
But well. Like I said, I didn't feel like wasting my time debugging the issue myself.
Updated by school.player over 13 years ago
Dude, the Radeon HD 5670 is ATI, not NVIDIA!
Updated by DimitriPilot3 over 13 years ago
I am not exactly sure what you mean.
Do you mean, by chance, thay my old "NVIDIA-only" guess for the crashes on stop was wrong because I somehow overlooked the "/GPU HD5670" part of the very first post? I was making that guess mainly for the video memory corruption and/or display driver crashes, because I didn't see many people with such (odd) problems.
Just so you know, by "NVIDIA", I was referring to my own GPU (NVIDIA GeForce 8800 GTS 512), as well as to my old "perhaps NVIDIA-only" guess (which I made up because I didn't see many people getting crashes in "~SharedPtr()", let alone video memory corruption and/or display driver crashes...).