Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Bug Game crashes on second launch: UnityShaderCache problem on AMD cards

Discussion in 'General Graphics' started by Deleted User, Mar 3, 2021.

  1. Deleted User

    Deleted User

    Guest

    Hello

    a relevant number of our alpha testers are having a serious but strange issue: they launch the game, play a bit, but when they try to play another time, the game crashes at start and keeps crashing each time they try launching the game.

    The crash message looks like this:
    Native Crash - Unknown Function (atio6axx)

    The Unity player log stops exactly when starting to load the shaders.

    We managed to find the cause in the unity shader cache. At the first launch the cache is built (no errors), but a crash happens when Unity tries to load the shader cache on some AMD graphics cards.
    Proof: if we make the tester delete the UnityShaderCache in the AppData\Local\Temp.. game folder, the game starts without crashing.

    We already made them update the graphics card drivers, with no results.

    The issue happened with these graphics card:
    Radeon RX 580 Series
    Radeon RX 470 Graphics
    AMD Radeon RX Vega 11 Graphics

    We found the problem on Unity 2019.4.7, then we moved to 2020.2.4 to see if the issue was already solved, but same problem.

    Now the questions:

    1. Is it a Unity issue, or a graphics card driver issue?

    2. Is there a way to force the deletion of the UnityShaderCache folder before starting up the game?

    3. Is there a way to enable some detailed log so we can understand which shader is causing the issue?

    Thanks!

    Example of stackTrace:

    Native StackTrace:

    Thread 0
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4de360b2 ?CreateGpuProgram@GfxDeviceClient@@UEAAPEAVGpuProgram@@W4ShaderGpuProgramType@@AEBU?$dynamic_array@E$0A@@@AEAVCreateGpuProgramOutput@@@Z
    4 UnityPlayer 0x00007ffe4e1369e6 ?Compile@SubProgram@ShaderLab@@AEAAXXZ
    5 UnityPlayer 0x00007ffe4e1374c1 ?GetMatchingSubProgram@Program@ShaderLab@@QEBAPEBVSubProgram@2@PEBVShader@@PEBVPass@2@AEBUShaderKeywordSet@@IPEAU6@AEAW4ShaderSnippetResult@@_N5@Z
    6 UnityPlayer 0x00007ffe4e13aac1 ?FindSubProgramsToUse@ShaderState@ShaderLab@@QEBA?AW4ShaderSnippetResult@@PEBVShader@@PEBVPass@2@AEAVSubPrograms@2@AEBUShaderPassContext@@_N@Z
    7 UnityPlayer 0x00007ffe4e139feb ?ApplyShaderState@ShaderState@ShaderLab@@QEBA?AVVertexInputMasks@@IPEBVShaderPropertySheet@@AEBUShaderPassContext@@PEAVShader@@PEAVPass@2@PEAVSubPrograms@2@PEBUDeviceRenderStateBlock@@@Z
    8 UnityPlayer 0x00007ffe4e133486 ?ApplyPass@Pass@ShaderLab@@QEAA?AVVertexInputMasks@@IPEBVShaderPropertySheet@@AEAUShaderPassContext@@PEAVShader@@HHPEBVGrabPasses@2@PEAVSubPrograms@2@PEBUDeviceRenderStateBlock@@@Z
    9 UnityPlayer 0x00007ffe4e12fceb DrawVBOChunkWithPass
    10 UnityPlayer 0x00007ffe4e132039 ?WarmupOneShaderImpl@ShaderVariantCollection@@QEAAXPEAVShader@@AEBV?$vector_set@UVariantInfo@ShaderVariantCollection@@U?$less@UVariantInfo@ShaderVariantCollection@@@std@@V?$allocator@UVariantInfo@ShaderVariantCollection@@@4@@@AEBUWarmupPassSetup@@PEAVDynamicVBO@@P6AX0HPEAVPass@ShaderLab@@AEBUShaderKeywordSet@@23PEAXAEAUShaderPassContext@@@Z6@Z
    11 UnityPlayer 0x00007ffe4e132889 ?WarmupShadersImpl@ShaderVariantCollection@@QEAAXP6AXPEAVShader@@HPEAVPass@ShaderLab@@AEBUShaderKeywordSet@@AEBUWarmupPassSetup@@PEAVDynamicVBO@@PEAXAEAUShaderPassContext@@@Z5@Z
    12 UnityPlayer 0x00007ffe4e13231c ?WarmupShaders@ShaderVariantCollection@@QEAAX_N@Z
    13 UnityPlayer 0x00007ffe4df4a349 ?WarmupPreloadedShaders@GraphicsSettings@@QEAAXXZ
    14 UnityPlayer 0x00007ffe4dc5d8f9 ?Invoke@CallbackArray@@QEAAXXZ
    15 UnityPlayer 0x00007ffe4e0e1a57 ?PlayerLoadFirstScene@@YAPEAVAsyncOperation@@_N@Z
    16 UnityPlayer 0x00007ffe4de90184 ?UnityMainImpl@@YAHPEAUHINSTANCE__@@0PEA_WH@Z
    17 UnityPlayer 0x00007ffe4de9404b UnityMain
    18 Saturnalia 0x00007ff6d86311f2 _scrt_common_main_seh
    19 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    20 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    21 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 1
    0 ntdll 0x00007ffebf200084 NtWaitForWorkViaWorkerFactory
    1 ntdll 0x00007ffebf193fe0 TppWorkerThread
    2 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    3 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    4 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 2
    0 ntdll 0x00007ffebf200084 NtWaitForWorkViaWorkerFactory
    1 ntdll 0x00007ffebf193fe0 TppWorkerThread
    2 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    3 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    4 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 3
    0 ntdll 0x00007ffebf200084 NtWaitForWorkViaWorkerFactory
    1 ntdll 0x00007ffebf193fe0 TppWorkerThread
    2 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    3 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    4 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 4
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 mono-2.0-bdwgc 0x00007ffe6ce45e8f mono_win32_wait_for_single_object_ex
    3 mono-2.0-bdwgc 0x00007ffe6cf342cd mono_os_sem_timedwait
    4 mono-2.0-bdwgc 0x00007ffe6cf330a5 finalizer_thread
    5 mono-2.0-bdwgc 0x00007ffe6cef6398 start_wrapper_internal
    6 mono-2.0-bdwgc 0x00007ffe6cef6126 start_wrapper
    7 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    9 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 5
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 6
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 7
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 8
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 9
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 10
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 11
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 12
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 13
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 14
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 15
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 16
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 17
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 18
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 19
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 20
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 21
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 22
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 23
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 24
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 25
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 26
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 27
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e08e6e0 ?ProcessJobs@JobQueue@@AEAAXPEAUThreadInfo@1@PEAX@Z
    4 UnityPlayer 0x00007ffe4e08f7b0 ?WorkLoop@JobQueue@@CAPEAXPEAX@Z
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 28
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4e17c05a ?HandleOutOfBufferToReadFrom@ThreadedStreamBuffer@@MEAA?AUDataOffsets@1@U21@@Z
    4 UnityPlayer 0x00007ffe4e0d268c BatchDeleteStep2Threaded
    5 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 29
    0 ntdll 0x00007ffebf1fc774 ZwWaitForSingleObject
    1 KERNELBASE 0x00007ffebcc41e93 WaitForSingleObjectEx
    2 UnityPlayer 0x00007ffe4e7d5892 Baselib_SystemSemaphore_Acquire
    3 UnityPlayer 0x00007ffe4df88c7d ?StaticThreadEntry@AsyncReadManagerThreaded@@CAPEAXPEAX@Z
    4 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    5 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    6 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 30 (crashed)
    0 ntdll 0x00007ffebf1fd244 ZwWaitForMultipleObjects
    1 KERNELBASE 0x00007ffebcc52ae7 WaitForMultipleObjectsEx
    2 KERNELBASE 0x00007ffebcc529ce WaitForMultipleObjects
    3 UnityPlayer 0x00007ffe4de5c55d ?HandleCrash@ExternalCrashHandler@winutils@@AEAAXKKPEBDPEAU_CONTEXT@@PEAU_EXCEPTION_RECORD@@_N@Z
    4 UnityPlayer 0x00007ffe4de5c602 ?HandleCrash@ExternalCrashHandler@winutils@@QEAA_NKKPEAU_EXCEPTION_POINTERS@@@Z
    5 UnityPlayer 0x00007ffe4de689a8 ?ProcessInternalCrash@winutils@@YAHPEAU_EXCEPTION_POINTERS@@_N@Z
    6 KERNELBASE 0x00007ffebcd0117a UnhandledExceptionFilter
    7 ntdll 0x00007ffebf205132 RtlUserThreadStart$filt$0
    8 ntdll 0x00007ffebf1eccd6 _C_specific_handler
    9 ntdll 0x00007ffebf20184f RtlpExecuteHandlerForException
    10 ntdll 0x00007ffebf1ca889 RtlDispatchException
    11 ntdll 0x00007ffebf2004be KiUserExceptionDispatch
    12 atio6axx 0x00007ffe5927f569 <system symbols missing>
    13 atio6axx 0x00007ffe58eba248 <system symbols missing>
    14 atio6axx 0x00007ffe593699d8 <system symbols missing>
    15 atio6axx 0x00007ffe5934fb4a <system symbols missing>
    16 atio6axx 0x00007ffe59350a52 <system symbols missing>
    17 atio6axx 0x00007ffe59366f9a <system symbols missing>
    18 atio6axx 0x00007ffe593641a6 <system symbols missing>
    19 atio6axx 0x00007ffe5936458d <system symbols missing>
    20 atio6axx 0x00007ffe59362673 <system symbols missing>
    21 atio6axx 0x00007ffe582f58d5 <system symbols missing>
    22 atio6axx 0x00007ffe5893e235 <system symbols missing>
    23 UnityPlayer 0x00007ffe4de2146e ?DrawArrays@ApiGLES@@QEAAXW4GfxPrimitiveType@@III@Z
    24 UnityPlayer 0x00007ffe4de0d53d ?DrawBufferRanges@GfxDeviceGLES@@IEAAXPEAVGfxBuffer@@IPEBQEAV2@PEBIHPEBUDrawBuffersRange@@HPEAVVertexDeclaration@@_KH@Z
    25 UnityPlayer 0x00007ffe4df9f9bf ?DrawBuffersStereo@SinglePassStereoSupportExt@@QEAAXPEAVGfxBuffer@@IPEBQEAV2@PEBIHPEBUDrawBuffersRange@@HPEAVVertexDeclaration@@_K@Z
    26 UnityPlayer 0x00007ffe4de0d7c9 ?DrawBuffers@GfxDeviceGLES@@UEAAXPEAVGfxBuffer@@IPEBQEAV2@PEBIHPEBUDrawBuffersRange@@HPEAVVertexDeclaration@@@Z
    27 UnityPlayer 0x00007ffe4e03561d ?DrawChunk@DynamicVBO@@UEAAXPEAVVertexDeclaration@@@Z
    28 UnityPlayer 0x00007ffe4de554d8 ?RunCommand@GfxDeviceWorker@@IEAA?AW4Status@1@AEAVThreadedStreamBuffer@@@Z
    29 UnityPlayer 0x00007ffe4de56c0d ?RunExt@GfxDeviceWorker@@MEAAXAEAVThreadedStreamBuffer@@@Z
    30 UnityPlayer 0x00007ffe4de56ce8 ?RunGfxDeviceWorker@GfxDeviceWorker@@KAPEAXPEAX@Z
    31 UnityPlayer 0x00007ffe4e17afe8 ?RunThreadWrapper@Thread@@CAKPEAX@Z
    32 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    33 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    34 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 31
    0 ntdll 0x00007ffebf1fd244 ZwWaitForMultipleObjects
    1 KERNELBASE 0x00007ffebcc52ae7 WaitForMultipleObjectsEx
    2 combase 0x00007ffebed7c97b <system symbols missing>
    3 combase 0x00007ffebed7c800 <system symbols missing>
    4 combase 0x00007ffebed7c62c <system symbols missing>
    5 combase 0x00007ffebed7c5ac <system symbols missing>
    6 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    7 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    8 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 32
    0 ntdll 0x00007ffebf200084 NtWaitForWorkViaWorkerFactory
    1 ntdll 0x00007ffebf193fe0 TppWorkerThread
    2 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    3 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    4 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart

    Thread 33
    0 ntdll 0x00007ffebf200084 NtWaitForWorkViaWorkerFactory
    1 ntdll 0x00007ffebf193fe0 TppWorkerThread
    2 KERNEL32 0x00007ffebea97c24 BaseThreadInitThunk
    3 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
    4 ntdll 0x00007ffebf1cd4d1 RtlUserThreadStart
     
  2. aleksandrk

    aleksandrk

    Unity Technologies

    Joined:
    Jul 3, 2017
    Posts:
    2,983
    @Paolo_Taje please report a bug - there is not enough information to understand, what exactly is happening here.
    1. Not enough information to answer this.
    2. Not built-in.
    3. There's a checkbox in the graphics settings to enable logging whenever a shader variant is compiled.
     
  3. Deleted User

    Deleted User

    Guest

    Hi aleksandrk, thanks for replying.

    Actually, I've found a way to add a workaround as point 2, with a class made like this, that seems to be called just before shader loading:

    Code (CSharp):
    1. class GameLoadClass
    2. {
    3.  
    4. #if UNITY_STANDALONE_WIN
    5.     [RuntimeInitializeOnLoadMethod(RuntimeInitializeLoadType.BeforeSplashScreen)]
    6.     static void OnBeforeLoadRuntimeMethod()
    7.     {
    8.         Debug.Log("Trying to delete UnityShaderCache");
    9.         Debug.Log("Application.temporaryCachePath: " + Application.temporaryCachePath);
    10.  
    11.         string shaderCacheFolder = Application.temporaryCachePath + "/UnityShaderCache";
    12.         DirectoryInfo di = new DirectoryInfo(shaderCacheFolder);
    13.  
    14.         int num = 0;
    15.         foreach (FileInfo file in di.GetFiles())
    16.         {
    17.             file.Delete();
    18.             num++;
    19.         }
    20.  
    21.         Debug.Log(num.ToString() + " Files deleted");
    22.     }
    23. #endif
    24. }
    I'll send a bug report, so you'll be able to repro the issue, thanks
     
    aleksandrk likes this.
  4. Deleted User

    Deleted User

    Guest

    I've opened a bug report with id 1319559
     
    aleksandrk likes this.
  5. jolix

    jolix

    Joined:
    May 22, 2016
    Posts:
    70
    Users are reporting this crash:

    atidxx64.dll caused an Access Violation (0xc0000005)
    in module atidxx64.dll at 0033:91b173df.

    They all have AMD cards:
    AMD Radeon(TM) Vega 8 Graphics
    AMD Radeon(TM) Vega 10 Graphics
    AMD Radeon(TM) Graphics (ID=0x1636)

    Unfortunately this fix doesn't work, because for some reason in my game there is no UnityShaderCache in AppData\Local\Temp\...
    The builds are Unity 2020.2.6f1.

    EDIT: Updating the AMD drivers have been reported to work.
     
    Last edited: Apr 6, 2021