locked
Concurrent ID3D11DeviceContext::Map calls on a same resource

    Question

  • Hello,

    I have a simple question but the answer seems so hard to obtain though.

    I have a same resource (say for instance a constant buffer ID3D11Buffer used to update a HLSL shader) shared by multiple objects which I want to update with ID3D11DeviceContext::Map (http://msdn.microsoft.com/en-us/library/windows/desktop/ff476457(v=vs.85).aspx). However, in the case the immediate context and the deferred context(s) (which run(s) in worker threads) try to call Map at the same time, will it create an error due to concurrent access to a same resource ?

    I heard that Map() calls on deferred contexts created a 'local copy of the mapped data' but so far I am still not sure about it.

    Knowing for sure that such concurrent calls are safe would be a great relief somewhat since it would give me more flexibility for my worker threads running the deferred contexts. 

    Best regards





    • Edited by Anveena Sunday, September 8, 2013 8:38 PM
    Sunday, September 8, 2013 8:31 PM

Answers

All replies