mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
fix: flush L3 cache and wait for flush to complete when event is completed
Related-To: NEO-8395 Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
556645e0c5
commit
c49695fa6e
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2023 Intel Corporation
|
||||
* Copyright (C) 2018-2024 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -722,8 +722,20 @@ bool Event::isCompleted() {
|
||||
|
||||
Range<CopyEngineState> states{&bcsState, bcsState.isValid() ? 1u : 0u};
|
||||
|
||||
if (cmdQueue->isCompleted(getCompletionStamp(), states) || this->areTimestampsCompleted()) {
|
||||
if (cmdQueue->isCompleted(getCompletionStamp(), states)) {
|
||||
gpuStateWaited = true;
|
||||
} else {
|
||||
if (this->areTimestampsCompleted()) {
|
||||
if (cmdQueue->getGpgpuCommandStreamReceiver().getDcFlushSupport()) {
|
||||
// also flush L3 and wait for cmd queue when L3 flush required
|
||||
auto waitStatus = cmdQueue->waitUntilComplete(taskCount.load(), states, flushStamp->peekStamp(), false, true, false);
|
||||
if (waitStatus == WaitStatus::ready) {
|
||||
this->gpuStateWaited = true;
|
||||
}
|
||||
} else {
|
||||
gpuStateWaited = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return gpuStateWaited;
|
||||
|
||||
Reference in New Issue
Block a user