SWDEV-313306 - Fix Co-operative groups dtests
Add a state indicator to retain ExternalSignals when needed. Co-operative group launch uses external signals to indicate a dependency to the next command. Change-Id: I6d0daa006e2377c3bbf4aeca0fd5b63c7ac8fbbb
이 커밋은 다음에 포함됨:
1 부모
e5122e3bc7
커밋
1fbd75b825
2 파일이 변경됨
+15
-8
검색과 일치하는 파일 없음
@@ -1008,6 +1008,7 @@ bool VirtualGPU::releaseGpuMemoryFence(bool skip_cpu_wait) {
|
||||
// Dispatch barrier packet into the queue
|
||||
dispatchBarrierPacket(kBarrierPacketHeader);
|
||||
hasPendingDispatch_ = false;
|
||||
retainExternalSignals_ = false;
|
||||
}
|
||||
|
||||
// Check if runtime could skip CPU wait
|
||||
@@ -1277,7 +1278,9 @@ void VirtualGPU::profilingBegin(amd::Command& command, bool drmProfiling) {
|
||||
}
|
||||
|
||||
if (AMD_DIRECT_DISPATCH) {
|
||||
Barriers().ClearExternalSignals();
|
||||
if (!retainExternalSignals_) {
|
||||
Barriers().ClearExternalSignals();
|
||||
}
|
||||
for (auto it = command.eventWaitList().begin(); it < command.eventWaitList().end(); ++it) {
|
||||
void* hw_event = ((*it)->NotifyEvent() != nullptr) ?
|
||||
(*it)->NotifyEvent()->HwEvent() : (*it)->HwEvent();
|
||||
@@ -1304,10 +1307,12 @@ void VirtualGPU::profilingEnd(amd::Command& command) {
|
||||
if (!timestamp_->HwProfiling()) {
|
||||
timestamp_->end();
|
||||
}
|
||||
assert(Barriers().IsExternalSignalListEmpty());
|
||||
command.setData(timestamp_);
|
||||
timestamp_ = nullptr;
|
||||
}
|
||||
if (AMD_DIRECT_DISPATCH) {
|
||||
assert(retainExternalSignals_ || Barriers().IsExternalSignalListEmpty());
|
||||
}
|
||||
}
|
||||
|
||||
// ================================================================================================
|
||||
@@ -2991,6 +2996,7 @@ void VirtualGPU::submitKernel(amd::NDRangeKernelCommand& vcmd) {
|
||||
// Add a dependency into the current queue on the coop queue
|
||||
Barriers().AddExternalSignal(queue->Barriers().GetLastSignal());
|
||||
hasPendingDispatch_ = true;
|
||||
retainExternalSignals_ = true;
|
||||
|
||||
queue->profilingEnd(vcmd);
|
||||
} else {
|
||||
|
||||
새 이슈에서 참조
사용자 차단