locked
DirectX: Leaked memory released on App Suspend

    Question

  • I have a DirectX application which seems to leak a few objects during its several runs (after opening and closing page SwapChainBackgroundPanel).

    The interesting thing is that these DirectX objects seem to be somehow released if the app is suspended via Visual Studio. What might be releasing the resources? I am asking this since I would like to do it myself to release the memory without needing App suspension.

    Below are the DirectX objects remain allocated after page close but deallocated with App Suspension.

    D3D11 INFO: Destroy ID3D11Texture2D: Name="unnamed", Addr=0x074E42E4 [ STATE_CREATION INFO #2097236: DESTROY_TEXTURE2D]
    D3D11 INFO: Destroy ID3D11Texture2D: Name="unnamed", Addr=0x074E3B4C [ STATE_CREATION INFO #2097236: DESTROY_TEXTURE2D]
    D3D11 INFO: Destroy ID3D11Query: Name="unnamed", Addr=0x07680234 [ STATE_CREATION INFO #2097281: DESTROY_QUERY]
    D3D11 INFO: Destroy ID3D11RasterizerState: Name="unnamed", Addr=0x0DBCB9EC [ STATE_CREATION INFO #2097278: DESTROY_RASTERIZERSTATE]
    D3D11 INFO: Destroy ID3D11DepthStencilState: Name="unnamed", Addr=0x0DBCC274 [ STATE_CREATION INFO #2097275: DESTROY_DEPTHSTENCILSTATE]
    D3D11 INFO: Destroy ID3D11BlendState: Name="unnamed", Addr=0x0DBCB8B4 [ STATE_CREATION INFO #2097272: DESTROY_BLENDSTATE]
    D3D11 INFO: Destroy ID3D11RenderTargetView: Name="unnamed", Addr=0x0DC839E4 [ STATE_CREATION INFO #2097245: DESTROY_RENDERTARGETVIEW]
    D3D11 INFO: Destroy ID3D11Texture2D: Name="unnamed", Addr=0x074E47F4 [ STATE_CREATION INFO #2097236: DESTROY_TEXTURE2D]
    D3D11 INFO: Destroy ID3DDeviceContextState: Name="unnamed", Addr=0x0770ECE0 [ STATE_CREATION INFO #3145749: DESTROY_DEVICECONTEXTSTATE]
    D3D11 INFO: Destroy ID3DDeviceContextState: Name="unnamed", Addr=0x07681DD8 [ STATE_CREATION INFO #3145749: DESTROY_DEVICECONTEXTSTATE]
    D3D11 INFO: Destroy ID3D11Sampler: Name="unnamed", Addr=0x0DBCBB24 [ STATE_CREATION INFO #2097269: DESTROY_SAMPLER]
    D3D11 INFO: Destroy ID3D11Context: Name="unnamed", Addr=0x0DC843E0 [ STATE_CREATION INFO #2097227: DESTROY_CONTEXT]
    D3D11 INFO: Destroy ID3DDeviceContextState: Name="unnamed", Addr=0x0765FFD8 [ STATE_CREATION INFO #3145749: DESTROY_DEVICECONTEXTSTATE]

    Tuesday, March 19, 2013 3:52 PM

All replies

  • Hi,

    How did you get the memory leak information? From Visual Studio or other tools?

    Best regards,
    Jesse


    Jesse Jiang
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Thursday, March 21, 2013 4:28 AM
  • Hi,

    I am getting the memory leak info from the Task Manager. Object destroy logs are output from DirectX Debug Layer which is activated with DirectX Control Panel.

    Thursday, March 21, 2013 7:16 AM