mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-24 20:39:56 +08:00
Lock csr inside executeCommandLists() to make submissions thread safe
Change-Id: I9326ee5bb835f01015668e66d2582df9ed02d66f
This commit is contained in:
committed by
sys_ocldev
parent
5dbf7d5f8c
commit
bf57f2d696
@@ -266,7 +266,7 @@ class CommandStreamReceiver {
|
||||
uint64_t totalMemoryUsed = 0u;
|
||||
|
||||
// taskCount - # of tasks submitted
|
||||
uint32_t taskCount = 0;
|
||||
std::atomic<uint32_t> taskCount{0};
|
||||
|
||||
uint32_t lastSentL3Config = 0;
|
||||
uint32_t latestSentStatelessMocsConfig = 0;
|
||||
|
||||
@@ -224,7 +224,7 @@ CompletionStamp CommandStreamReceiverHw<GfxFamily>::flushTask(
|
||||
args);
|
||||
|
||||
this->latestSentTaskCount = taskCount + 1;
|
||||
DBG_LOG(LogTaskCounts, __FUNCTION__, "Line: ", __LINE__, "taskCount", taskCount);
|
||||
DBG_LOG(LogTaskCounts, __FUNCTION__, "Line: ", __LINE__, "taskCount", peekTaskCount());
|
||||
if (DebugManager.flags.AddPatchInfoCommentsForAUBDump.get()) {
|
||||
flatBatchBufferHelper->setPatchInfoData(PatchInfoData(address, 0u,
|
||||
PatchInfoAllocationType::TagAddress,
|
||||
@@ -421,7 +421,7 @@ CompletionStamp CommandStreamReceiverHw<GfxFamily>::flushTask(
|
||||
MemorySynchronizationCommands<GfxFamily>::addPipeControl(commandStreamCSR, args);
|
||||
}
|
||||
this->taskLevel = taskLevel;
|
||||
DBG_LOG(LogTaskCounts, __FUNCTION__, "Line: ", __LINE__, "this->taskCount", this->taskCount);
|
||||
DBG_LOG(LogTaskCounts, __FUNCTION__, "Line: ", __LINE__, "this->taskCount", peekTaskCount());
|
||||
}
|
||||
|
||||
if (DebugManager.flags.ForcePipeControlPriorToWalker.get()) {
|
||||
@@ -545,7 +545,7 @@ CompletionStamp CommandStreamReceiverHw<GfxFamily>::flushTask(
|
||||
}
|
||||
|
||||
++taskCount;
|
||||
DBG_LOG(LogTaskCounts, __FUNCTION__, "Line: ", __LINE__, "taskCount", taskCount);
|
||||
DBG_LOG(LogTaskCounts, __FUNCTION__, "Line: ", __LINE__, "taskCount", peekTaskCount());
|
||||
DBG_LOG(LogTaskCounts, __FUNCTION__, "Line: ", __LINE__, "Current taskCount:", tagAddress ? *tagAddress : 0);
|
||||
|
||||
CompletionStamp completionStamp = {
|
||||
|
||||
Reference in New Issue
Block a user