refactor: correct naming of enum class constants

EngineGroupType
BlitDirection
PostBlitMode
WaitStatus

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2023-12-01 09:12:59 +00:00
committed by Compute-Runtime-Automation
parent 9cc1a23ab6
commit e57d372608
184 changed files with 1485 additions and 1485 deletions

View File

@@ -449,7 +449,7 @@ bool CommandQueue::isCompleted(TaskCountType gpgpuTaskCount, const Range<CopyEng
WaitStatus CommandQueue::waitUntilComplete(TaskCountType gpgpuTaskCountToWait, Range<CopyEngineState> copyEnginesToWait, FlushStamp flushStampToWait, bool useQuickKmdSleep, bool cleanTemporaryAllocationList, bool skipWait) {
WAIT_ENTER()
WaitStatus waitStatus{WaitStatus::Ready};
WaitStatus waitStatus{WaitStatus::ready};
DBG_LOG(LogTaskCounts, __FUNCTION__, "Waiting for taskCount:", gpgpuTaskCountToWait);
DBG_LOG(LogTaskCounts, __FUNCTION__, "Line: ", __LINE__, "Current taskCount:", getHwTag());
@@ -462,8 +462,8 @@ WaitStatus CommandQueue::waitUntilComplete(TaskCountType gpgpuTaskCountToWait, R
flushStampToWait,
useQuickKmdSleep,
this->getThrottle());
if (waitStatus == WaitStatus::GpuHang) {
return WaitStatus::GpuHang;
if (waitStatus == WaitStatus::gpuHang) {
return WaitStatus::gpuHang;
}
DEBUG_BREAK_IF(getHwTag() < gpgpuTaskCountToWait);
@@ -476,8 +476,8 @@ WaitStatus CommandQueue::waitUntilComplete(TaskCountType gpgpuTaskCountToWait, R
auto bcsCsr = getBcsCommandStreamReceiver(copyEngine.engineType);
waitStatus = bcsCsr->waitForTaskCountWithKmdNotifyFallback(copyEngine.taskCount, 0, false, this->getThrottle());
if (waitStatus == WaitStatus::GpuHang) {
return WaitStatus::GpuHang;
if (waitStatus == WaitStatus::gpuHang) {
return WaitStatus::gpuHang;
}
}
} else if (gtpinIsGTPinInitialized()) {
@@ -488,8 +488,8 @@ WaitStatus CommandQueue::waitUntilComplete(TaskCountType gpgpuTaskCountToWait, R
auto bcsCsr = getBcsCommandStreamReceiver(copyEngine.engineType);
waitStatus = bcsCsr->waitForTaskCountAndCleanTemporaryAllocationList(copyEngine.taskCount);
if (waitStatus == WaitStatus::GpuHang) {
return WaitStatus::GpuHang;
if (waitStatus == WaitStatus::gpuHang) {
return WaitStatus::gpuHang;
}
}
@@ -1284,14 +1284,14 @@ WaitStatus CommandQueue::waitForAllEngines(bool blockedQueue, PrintfHandler *pri
}
}
auto waitStatus = WaitStatus::NotReady;
auto waitStatus = WaitStatus::notReady;
bool waitedOnTimestamps = false;
// TSP for OOQ dispatch is optional. We need to wait for task count.
if (!isOOQEnabled()) {
waitedOnTimestamps = waitForTimestamps(activeBcsStates, waitStatus, this->timestampPacketContainer.get(), this->deferredTimestampPackets.get());
if (waitStatus == WaitStatus::GpuHang) {
return WaitStatus::GpuHang;
if (waitStatus == WaitStatus::gpuHang) {
return WaitStatus::gpuHang;
}
}
@@ -1322,7 +1322,7 @@ WaitStatus CommandQueue::waitForAllEngines(bool blockedQueue, PrintfHandler *pri
if (printfHandler) {
if (!printfHandler->printEnqueueOutput()) {
return WaitStatus::GpuHang;
return WaitStatus::gpuHang;
}
}

View File

@@ -143,7 +143,7 @@ bool CommandQueueHw<Family>::isCacheFlushForBcsRequired() const {
template <typename TSPacketType>
inline bool waitForTimestampsWithinContainer(TimestampPacketContainer *container, CommandStreamReceiver &csr, WaitStatus &status) {
bool waited = false;
status = WaitStatus::NotReady;
status = WaitStatus::notReady;
if (container) {
auto lastHangCheckTime = std::chrono::high_resolution_clock::now();
@@ -153,11 +153,11 @@ inline bool waitForTimestampsWithinContainer(TimestampPacketContainer *container
csr.downloadAllocation(*timestamp->getBaseGraphicsAllocation()->getGraphicsAllocation(csr.getRootDeviceIndex()));
WaitUtils::waitFunctionWithPredicate<const TSPacketType>(static_cast<TSPacketType const *>(timestamp->getContextEndAddress(i)), 1u, std::not_equal_to<TSPacketType>());
if (csr.checkGpuHangDetected(std::chrono::high_resolution_clock::now(), lastHangCheckTime)) {
status = WaitStatus::GpuHang;
status = WaitStatus::gpuHang;
return false;
}
}
status = WaitStatus::Ready;
status = WaitStatus::ready;
waited = true;
}
}

View File

@@ -472,11 +472,11 @@ cl_int CommandQueueHw<GfxFamily>::enqueueHandler(Surface **surfacesForResidency,
queueOwnership.unlock();
if (blocking) {
auto waitStatus = WaitStatus::Ready;
auto waitStatus = WaitStatus::ready;
auto &builtinOpParams = multiDispatchInfo.peekBuiltinOpParams();
if (builtinOpParams.userPtrForPostOperationCpuCopy) {
waitStatus = waitForAllEngines(blockQueue, (blockQueue ? nullptr : printfHandler.get()), false);
if (waitStatus == WaitStatus::GpuHang) {
if (waitStatus == WaitStatus::gpuHang) {
return CL_OUT_OF_RESOURCES;
}
@@ -491,7 +491,7 @@ cl_int CommandQueueHw<GfxFamily>::enqueueHandler(Surface **surfacesForResidency,
waitStatus = waitForAllEngines(blockQueue, (blockQueue ? nullptr : printfHandler.get()), true);
}
if (waitStatus == WaitStatus::GpuHang) {
if (waitStatus == WaitStatus::gpuHang) {
return CL_OUT_OF_RESOURCES;
}
}
@@ -1491,7 +1491,7 @@ cl_int CommandQueueHw<GfxFamily>::enqueueBlit(const MultiDispatchInfo &multiDisp
bcsCommandStreamReceiverOwnership.unlock();
if (blocking) {
const auto waitStatus = waitForAllEngines(blockQueue, nullptr);
if (waitStatus == WaitStatus::GpuHang) {
if (waitStatus == WaitStatus::gpuHang) {
return CL_OUT_OF_RESOURCES;
}
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2018-2022 Intel Corporation
* Copyright (C) 2018-2023 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
@@ -22,7 +22,7 @@ cl_int CommandQueueHw<GfxFamily>::finish() {
// Stall until HW reaches taskCount on all its engines
const auto waitStatus = waitForAllEngines(true, nullptr);
if (waitStatus == WaitStatus::GpuHang) {
if (waitStatus == WaitStatus::gpuHang) {
return CL_OUT_OF_RESOURCES;
}