Search Unity

[8.0] WACK: Test of DirectX support for feature level 9_1 fails due to crash

Discussion in 'Windows' started by Thomas-GF, Feb 12, 2014.

  1. Thomas-GF

    Thomas-GF

    Joined:
    Apr 4, 2013
    Posts:
    28
    Hello,

    when targeting 8.0 the WACK DirectX Test for Feature Level 9_1 fails because the app crashes on start. I tested it three times, behaviour is always identical. The app crashes almost instantly after start. Only the native splash screen is visible by then.

    After the crashes I decided to test the Debug-version so I can have a look at the crash dump with symbols for UnityPlayer.dll. Here's the call stack:

    UnityPlayer.dll!FixedFunctionProgramD3D11::FixedFunctionProgramD3D11(const FixedFunctionStateD3D11 state) Zeile 677 C++
    UnityPlayer.dll!GetFixedFunctionProgram11(std::map<FixedFunctionStateD3D11,FixedFunctionProgramD3D11 *,FixedFuncStateCompareD3D11,std::allocator<std:: pair<FixedFunctionStateD3D11 const ,FixedFunctionProgramD3D11 *> > > cache, const FixedFunctionStateD3D11 state) Zeile 193 C++
    UnityPlayer.dll!GfxDeviceD3D11::BeforeDrawCall(bool immediateMode) Zeile 451 C++
    UnityPlayer.dll!GfxDeviceD3D11::ImmediateEndSetup() Zeile 1953 C++
    UnityPlayer.dll!GfxDeviceD3D11::ImmediateEnd() Zeile 2005 C++
    UnityPlayer.dll!GfxDeviceWorker::RunCommand(ThreadedStreamBuffer stream) Zeile 1111 C++
    UnityPlayer.dll!GfxDeviceWorker::Run() Zeile 243 C++
    UnityPlayer.dll!GfxDeviceWorker::RunGfxDeviceWorker(void * data) Zeile 211 C++
    UnityPlayer.dll!Thread::RunThreadWrapper(void * ptr) Zeile 40 C++
    UnityPlayer.dll!win32::CreateThread::__l22::<lambda>(Windows::Foundation::IAsyncAction ^ __formal) Zeile 273 C++
    UnityPlayer.dll!Platform:: Details::__abi_FunctorCapture1<void <lambda>(Windows::Foundation::IAsyncAction ^),void,Windows::Foundation::IAsyncAction ^>::Invoke(Windows::Foundation::IAsyncAction ^ __arg0) Zeile 857 C++
    UnityPlayer.dll!Windows::System::Threading::WorkItemHandler::Invoke(Windows::Foundation::IAsyncAction ^ __param0) C++
    UnityPlayer.dll!Windows::System::Threading::WorkItemHandler::[Windows::System::Threading::WorkItemHandler::__abi_IDelegate]::__abi_Windows_System_Threading_WorkItemHandler___abi_IDelegate____abi_Invoke(Windows::Foundation::IAsyncAction ^ __param0) C++
    threadpoolwinrt.dll!Windows::System::Threading::CThreadPoolWorkItem::CommonWorkCallback(void) Unbekannt
    threadpoolwinrt.dll!Windows::System::Threading::CThreadPoolWorkItem::TimeSlicedCallback(void *) Unbekannt
    kernel32.dll!@BaseThreadInitThunk@12() Unbekannt
    ntdll.dll!__RtlUserThreadStart() Unbekannt
    ntdll.dll!__RtlUserThreadStart@8() Unbekannt

    Best,

    Thomas
     
  2. Thomas-GF

    Thomas-GF

    Joined:
    Apr 4, 2013
    Posts:
    28
    It's exception code 0xC0000005 by the way. He tries to read 0x00000000.
     
  3. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    3,736
    Are you running on Windows 8.1 machine? There was a bug where 8.0 debug configuration crashes, when running on 8.1 machine and I don't think this fix is in 4.3.
     
  4. Thomas-GF

    Thomas-GF

    Joined:
    Apr 4, 2013
    Posts:
    28
    Yes I am on 8.1. However, not only the Debug build crashes. Usually I run the WACK tests agains the Master build, and this is where it crashed three times in a row.
     
  5. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    3,736
    Does this happen on a particular project or are you able to reproduce it with small project too?
     
  6. Thomas-GF

    Thomas-GF

    Joined:
    Apr 4, 2013
    Posts:
    28
    Empty Win 8 Project passes :-/

    My first scene, the one that's loaded on start, only displays a splashscreen.
    It adjusts the viewport and aspect ratio. It has two seperate cams, one to clear screen borders, one to display the splashscreen centrally on the screen.
    The splashscreen itself is loaded using Resources.Load() and drawn using GL commands including Vertex, Color and Texcoord, LoadOrtho and MultMatrix.
    In the background, a texture asset is read using GetPixels32().
     
  7. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    3,736
    If you make a small projects which only has a splashscreen, does it fail WACK?
    You can also try to comment-out certain GL calls and see, if it changes anything.
    I tmight be a bug, so it would be nice to narrow it down to it's cause.
     
  8. Thomas-GF

    Thomas-GF

    Joined:
    Apr 4, 2013
    Posts:
    28
    Hi, commenting out the GL-calls makes the test pass. I'm having a closer look at it...
     
  9. Thomas-GF

    Thomas-GF

    Joined:
    Apr 4, 2013
    Posts:
    28
    Okay, I got it.

    Initially we developed our App for mobile platforms, which is why we use "Mobile/..."-shaders practically everywhere. It does seem that "Mobile/Vertex Colored" is not compatible with 9_1 on Windows Store 8.0, because as soon as I render it either with GL.Vertex or on a standard Quad GameObject, the app crashes. If I use another shader like "Diffuse", the 9_1 WACK test passes.

    I just sent you a bug report (591145).