bradyrussell / marchingcubesterrainplugin

A UE4 plugin that provides infinite procedural terrain
https://github.com/bradyrussell/marchingcubesterrainplugin
4 stars 3 forks source link

D3D11: Removing Device crash after multiple minutes of idling #27

Closed bradyrussell closed 4 years ago

bradyrussell commented 4 years ago

I noticed when I would leave the game running and get off my PC, when I come back it would be crashed due to D3D11: Removing Device. Each time in my testing it happens after two or three minutes after activity stops, see logs where autosave is every minute

[2020.01.04-19.21.23:175][312]LogTemp: Warning: ----> Server sent 19.499023 kilobytes of compressed region data, with 56 regions. [2020.01.04-19.21.23:602][352]LogTemp: Warning: ----> Server sent 1.141602 kilobytes of compressed region data, with 8 regions. [2020.01.04-19.21.24:230][413]LogTemp: Warning: ----> Server sent 25.665039 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.21.29:977][ 45]LogTemp: Warning: ----> Server sent 24.156250 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.21.32:181][306]LogTemp: Warning: ----> Server sent 23.717773 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.21.41:314][396]Cmd: LevelEditor.ToggleImmersive The thread 0x2c8 has exited with code 0 (0x0). The thread 0xa28 has exited with code 0 (0x0). The thread 0x199c has exited with code 0 (0x0). The thread 0x4e0 has exited with code 0 (0x0). The thread 0x21ec has exited with code 0 (0x0). The thread 0x454 has exited with code 0 (0x0). The thread 0x21cc has exited with code 0 (0x0). The thread 0x3b94 has exited with code 0 (0x0). The thread 0x2f60 has exited with code 0 (0x0). The thread 0x1094 has exited with code 0 (0x0). The thread 0x284c has exited with code 0 (0x0). The thread 0x38c8 has exited with code 0 (0x0). [2020.01.04-19.21.48:780][279]LogTemp: Warning: ----> Server sent 22.989258 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.21.56:419][184]LogTemp: Warning: ----> Server sent 22.909180 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.21.56:989][248]LogTemp: Warning: ----> Server sent 24.550781 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.22.04:775][181]LogBlueprintUserMessages: [OldPagedWorld_2] Server: Autosaving... [2020.01.04-19.22.04:817][181]LogBlueprintUserMessages: [OldPagedWorld_2] Server: Autosave complete. [2020.01.04-19.22.06:576][393]LogTemp: Warning: ----> Server sent 22.909180 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.22.08:802][565]LogTemp: Warning: ----> Server sent 24.550781 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.22.14:777][273]LogTemp: Warning: ----> Server sent 22.909180 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.22.15:977][415]LogTemp: Warning: ----> Server sent 21.375000 kilobytes of compressed region data, with 56 regions. [2020.01.04-19.22.16:408][462]LogTemp: Warning: ----> Server sent 2.640625 kilobytes of compressed region data, with 8 regions. [2020.01.04-19.22.16:979][529]LogTemp: Warning: ----> Server sent 22.333008 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.22.18:178][670]LogTemp: Warning: ----> Server sent 24.550781 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.22.20:578][957]LogTemp: Warning: ----> Server sent 22.909180 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.22.32:379][371]LogTemp: Warning: ----> Server sent 22.835938 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.22.40:013][279]LogTemp: Warning: ----> Server sent 22.764648 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.23.04:775][248]LogBlueprintUserMessages: [OldPagedWorld_2] Server: Autosaving... [2020.01.04-19.23.04:813][248]LogBlueprintUserMessages: [OldPagedWorld_2] Server: Autosave complete. [2020.01.04-19.23.35:575][934]LogTemp: Warning: ----> Server sent 24.214844 kilobytes of compressed region data, with 64 regions. [2020.01.04-19.23.37:791][128]LogTemp: Warning: ----> Server sent 6.101563 kilobytes of compressed region data, with 42 regions. [2020.01.04-19.23.38:010][148]LogTemp: Warning: ----> Server sent 2.167969 kilobytes of compressed region data, with 15 regions. [2020.01.04-19.23.38:184][167]LogTemp: Warning: ----> Server sent 1.023438 kilobytes of compressed region data, with 7 regions. The thread 0x3980 has exited with code 0 (0x0). [2020.01.04-19.24.04:774][357]LogBlueprintUserMessages: [OldPagedWorld_2] Server: Autosaving... [2020.01.04-19.24.04:809][357]LogBlueprintUserMessages: [OldPagedWorld_2] Server: Autosave complete. [2020.01.04-19.25.04:772][547]LogBlueprintUserMessages: [OldPagedWorld_2] Server: Autosaving... [2020.01.04-19.25.04:772][547]LogBlueprintUserMessages: [OldPagedWorld_2] Server: Autosave complete. D3D11: Removing Device.

``

bradyrussell commented 4 years ago

Fatal error: [File:F:/UE4_24/UE4_24/Engine/Source/Runtime/RenderCore/Private/RenderingThread.cpp] [Line: 853] Rendering thread exception: Fatal error: [File:F:/UE4_24/UE4_24/Engine/Source/Runtime/Windows/D3D11RHI/Private/D3D11Util.cpp] [Line: 198] Unreal Engine is exiting due to D3D device being lost. (Error: 0x887A0006 - 'HUNG')

Unhandled Exception: 0x00008000

0x00007ffd4f0f9159 KERNELBASE.dll!UnknownFunction [] 0x00007ffcfb34f936 UE4Editor-Core.dll!ReportGPUCrash() [f:\ue4_24\ue4_24\engine\source\runtime\core\private\windows\windowsplatformcrashcontext.cpp:1352] 0x00007ffcfb350dea UE4Editor-Core.dll!FWindowsErrorOutputDevice::Serialize() [f:\ue4_24\ue4_24\engine\source\runtime\core\private\windows\windowserroroutputdevice.cpp:74] 0x00007ffcfb1344dd UE4Editor-Core.dll!FOutputDevice::LogfImpl() [f:\ue4_24\ue4_24\engine\source\runtime\core\private\misc\outputdevice.cpp:71] 0x00007ffce59613c9 UE4Editor-D3D11RHI.dll!TerminateOnDeviceRemoved() [f:\ue4_24\ue4_24\engine\source\runtime\windows\d3d11rhi\private\d3d11util.cpp:208] 0x00007ffce5965b9f UE4Editor-D3D11RHI.dll!VerifyD3D11Result() [f:\ue4_24\ue4_24\engine\source\runtime\windows\d3d11rhi\private\d3d11util.cpp:256] 0x00007ffce59460e3 UE4Editor-D3D11RHI.dll!FD3D11RenderQueryBatcher::PollQueryResults() [f:\ue4_24\ue4_24\engine\source\runtime\windows\d3d11rhi\private\d3d11query.cpp:86] 0x00007ffce595460c UE4Editor-D3D11RHI.dll!FD3D11DynamicRHI::RHIPerFrameRHIFlushComplete() [f:\ue4_24\ue4_24\engine\source\runtime\windows\d3d11rhi\private\windows\windowsd3d11device.cpp:1776] 0x00007ffd0ff841af UE4Editor-RHI.dll!FRHIResource::FlushPendingDeletes() [f:\ue4_24\ue4_24\engine\source\runtime\rhi\private\rhi.cpp:315] 0x00007ffcedede098 UE4Editor-Renderer.dll!FDeferredShadingSceneRenderer::Render() [f:\ue4_24\ue4_24\engine\source\runtime\renderer\private\deferredshadingrenderer.cpp:1138] 0x00007ffcee315229 UE4Editor-Renderer.dll!RenderViewFamily_RenderThread() [f:\ue4_24\ue4_24\engine\source\runtime\renderer\private\scenerendering.cpp:3477] 0x00007ffcee2ef47c UE4Editor-Renderer.dll!TGraphTask<TEnqueueUniqueRenderCommandType<FRendererModule::BeginRenderingViewFamily'::35'::FDrawSceneCommandName, > >::ExecuteTask() [f:\ue4_24\ue4_24\engine\source\runtime\core\public\async\taskgraphinterfaces.h:847] 0x00007ffcfaefa152 UE4Editor-Core.dll!FNamedTaskThread::ProcessTasksNamedThread() [f:\ue4_24\ue4_24\engine\source\runtime\core\private\async\taskgraph.cpp:686] 0x00007ffcfaefa4f3 UE4Editor-Core.dll!FNamedTaskThread::ProcessTasksUntilQuit() [f:\ue4_24\ue4_24\engine\source\runtime\core\private\async\taskgraph.cpp:583] 0x00007ffd11675391 UE4Editor-RenderCore.dll!RenderingThreadMain() [f:\ue4_24\ue4_24\engine\source\runtime\rendercore\private\renderingthread.cpp:340] 0x00007ffd1167e254 UE4Editor-RenderCore.dll!FRenderingThread::Run() [f:\ue4_24\ue4_24\engine\source\runtime\rendercore\private\renderingthread.cpp:471] 0x00007ffcfb36e37f UE4Editor-Core.dll!FRunnableThreadWin::Run() [f:\ue4_24\ue4_24\engine\source\runtime\core\private\windows\windowsrunnablethread.cpp:96] 0x00007ffcfb365591 UE4Editor-Core.dll!FRunnableThreadWin::GuardedRun() [f:\ue4_24\ue4_24\engine\source\runtime\core\private\windows\windowsrunnablethread.cpp:53] 0x00007ffd4fd37974 KERNEL32.DLL!UnknownFunction [] 0x00007ffd521aa271 ntdll.dll!UnknownFunction []

this was in a Play in New Window session

bradyrussell commented 4 years ago

this is very likely related to #32 and I have to say this seems new, i definitely have let the game run for a while previously. the only other thing it could be is a view dist of 5 making it occur in <10 min. ill try playing with lower view distance

bradyrussell commented 4 years ago

this does happen in cubic mode as well. this is present in 4.22 VoxelShooter

bradyrussell commented 4 years ago

fantastic I have a copy of the plugin on 4.22 that has the issue and one on 4.22 without the issue (PlanetVox2) tomorrow I will cross reference the rendering (also I like the textures, lighting and Worldgen dont forget to migrate)

bradyrussell commented 4 years ago

it looks like this still happens as of rmc v 4 update however its only when the game is left completely idle. ive seen some reports of the same issue in other ue games so im assuming its something to do with the GPU trying to save power and turning off.

it is not an issue if for instance the player is moving, even if no input is entered for 10+ minutes in an autorun situation

bradyrussell commented 4 years ago

This may be related to Geforce experience?

bradyrussell commented 4 years ago

https://issues.unrealengine.com/issue/UE-51650

I'm switching to dx12 to see if that helps

bradyrussell commented 4 years ago

This has not happened since switching to DX 12. I am content with making that the minimum requirement.