mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-24 21:18:24 +08:00
Remove not needed code.
Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
107db3a372
commit
bfacd14b61
@@ -401,7 +401,6 @@ class CommandQueue : public BaseObject<_cl_command_queue> {
|
||||
QueuePriority priority = QueuePriority::MEDIUM;
|
||||
QueueThrottle throttle = QueueThrottle::MEDIUM;
|
||||
EnqueueProperties::Operation latestSentEnqueueType = EnqueueProperties::Operation::None;
|
||||
bool wasNonKernelOperationSent = false;
|
||||
uint64_t sliceCount = QueueSliceCount::defaultSliceCount;
|
||||
std::array<CopyEngineState, bcsInfoMaskSize> bcsStates = {};
|
||||
|
||||
|
||||
@@ -159,7 +159,7 @@ bool CommandQueueHw<Family>::waitForTimestamps(uint32_t taskCount) {
|
||||
using TSPacketType = typename Family::TimestampPacketType;
|
||||
bool waited = false;
|
||||
|
||||
if (isWaitForTimestampsEnabled() && !this->wasNonKernelOperationSent) {
|
||||
if (isWaitForTimestampsEnabled()) {
|
||||
waited = waitForTimestampsWithinContainer<TSPacketType>(timestampPacketContainer.get(), getGpgpuCommandStreamReceiver());
|
||||
|
||||
if (isOOQEnabled()) {
|
||||
@@ -167,8 +167,6 @@ bool CommandQueueHw<Family>::waitForTimestamps(uint32_t taskCount) {
|
||||
}
|
||||
}
|
||||
|
||||
this->wasNonKernelOperationSent = false;
|
||||
|
||||
return waited;
|
||||
}
|
||||
|
||||
|
||||
@@ -259,8 +259,6 @@ void CommandQueueHw<GfxFamily>::enqueueHandler(Surface **surfacesForResidency,
|
||||
|
||||
bool migratedMemory = false;
|
||||
|
||||
this->wasNonKernelOperationSent |= enqueueProperties.operation != EnqueueProperties::Operation::GpuKernel;
|
||||
|
||||
if (!blockQueue && multiDispatchInfo.peekMainKernel() && multiDispatchInfo.peekMainKernel()->requiresMemoryMigration()) {
|
||||
for (auto &arg : multiDispatchInfo.peekMainKernel()->getMemObjectsToMigrate()) {
|
||||
MigrationController::handleMigration(*this->context, computeCommandStreamReceiver, arg.second);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2021 Intel Corporation
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -911,48 +911,6 @@ HWTEST_F(TimestampPacketTests, givenEnableTimestampWaitWhenFinishThenCallWaitUti
|
||||
cmdQ.reset();
|
||||
}
|
||||
|
||||
HWTEST_F(TimestampPacketTests, givenEnableTimestampWaitAndNonGpuKernelEnqueueWhenFinishThenDoNotCallWaitUtils) {
|
||||
DebugManagerStateRestore restorer;
|
||||
DebugManager.flags.UpdateTaskCountFromWait.set(3);
|
||||
DebugManager.flags.EnableTimestampWait.set(1);
|
||||
|
||||
device->getUltCommandStreamReceiver<FamilyType>().timestampPacketWriteEnabled = true;
|
||||
cl_queue_properties props[3] = {CL_QUEUE_PROPERTIES, CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE, 0};
|
||||
auto cmdQ = std::make_unique<MockCommandQueueHw<FamilyType>>(context, device.get(), props);
|
||||
|
||||
TimestampPacketContainer *deferredTimestampPackets = cmdQ->deferredTimestampPackets.get();
|
||||
TimestampPacketContainer *timestampPacketContainer = cmdQ->timestampPacketContainer.get();
|
||||
|
||||
cmdQ->enqueueKernel(kernel->mockKernel, 1, nullptr, gws, nullptr, 0, nullptr, nullptr);
|
||||
cmdQ->enqueueKernel(kernel->mockKernel, 1, nullptr, gws, nullptr, 0, nullptr, nullptr);
|
||||
cmdQ->enqueueMarkerWithWaitList(0, nullptr, nullptr);
|
||||
cmdQ->flush();
|
||||
|
||||
EXPECT_EQ(1u, deferredTimestampPackets->peekNodes().size());
|
||||
EXPECT_EQ(1u, timestampPacketContainer->peekNodes().size());
|
||||
|
||||
VariableBackup<volatile uint32_t *> backupPauseAddress(&CpuIntrinsicsTests::pauseAddress);
|
||||
VariableBackup<uint32_t> backupPauseValue(&CpuIntrinsicsTests::pauseValue);
|
||||
VariableBackup<uint32_t> backupPauseOffset(&CpuIntrinsicsTests::pauseOffset);
|
||||
VariableBackup<std::function<void()>> backupSetupPauseAddress(&CpuIntrinsicsTests::setupPauseAddress);
|
||||
|
||||
deferredTimestampPackets->peekNodes()[0]->setPacketsUsed(1u);
|
||||
timestampPacketContainer->peekNodes()[0]->setPacketsUsed(1u);
|
||||
|
||||
CpuIntrinsicsTests::pauseAddress = reinterpret_cast<volatile uint32_t *>(const_cast<void *>(timestampPacketContainer->peekNodes()[0]->getContextEndAddress(0u)));
|
||||
CpuIntrinsicsTests::pauseValue = 2u;
|
||||
CpuIntrinsicsTests::setupPauseAddress = [&]() {
|
||||
CpuIntrinsicsTests::pauseAddress = reinterpret_cast<volatile uint32_t *>(const_cast<void *>(deferredTimestampPackets->peekNodes()[0]->getContextEndAddress(0u)));
|
||||
};
|
||||
CpuIntrinsicsTests::pauseCounter = 0u;
|
||||
|
||||
cmdQ->finish();
|
||||
|
||||
EXPECT_EQ(0u, CpuIntrinsicsTests::pauseCounter);
|
||||
|
||||
cmdQ.reset();
|
||||
}
|
||||
|
||||
HWTEST_F(TimestampPacketTests, givenTimestampPacketWriteEnabledWhenEnqueueingToOoqThenMoveToDeferredList) {
|
||||
device->getUltCommandStreamReceiver<FamilyType>().timestampPacketWriteEnabled = true;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user