mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-04 09:00:44 +00:00
Comment about thread safety requirements in Spirv debugger ids container
This commit is contained in:
@@ -209,6 +209,7 @@ private:
|
||||
T dummy;
|
||||
};
|
||||
|
||||
// This must be a thread safe container
|
||||
template <typename T>
|
||||
class DenseIdMap : public rdcarray<T>
|
||||
{
|
||||
|
||||
@@ -329,6 +329,7 @@ void ThreadState::EnterFunction(const rdcarray<Id> &arguments)
|
||||
SkipIgnoredInstructions();
|
||||
}
|
||||
|
||||
// This must be thread safe : it is called from multiple threads
|
||||
const ShaderVariable &ThreadState::GetSrc(Id id) const
|
||||
{
|
||||
return ids[id];
|
||||
|
||||
@@ -286,6 +286,7 @@ struct ThreadState
|
||||
// thread-local private variables
|
||||
rdcarray<ShaderVariable> privates;
|
||||
|
||||
// This must be a thread safe container
|
||||
// every ID's variable, if a pointer it may be pointing at a ShaderVariable stored elsewhere
|
||||
DenseIdMap<ShaderVariable> ids;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user