Check EnableTimestampPacket debug variable once and set as CSR mode

Change-Id: Ia6e7caa96f3b46b30590fb46a1fb37fa153adeb4
This commit is contained in:
Dunajski, Bartosz
2018-09-06 09:03:07 +02:00
committed by sys_ocldev
parent a8beec98e0
commit b74280beb6
11 changed files with 41 additions and 28 deletions

View File

@@ -1577,9 +1577,8 @@ HWTEST_F(EnqueueKernelTest, givenNonVMEKernelWhenEnqueueKernelThenDispatchFlagsD
}
HWTEST_F(EnqueueKernelTest, givenTimestampPacketWhenEnqueueingNonBlockedThenMakeItResident) {
DebugManagerStateRestore restore;
DebugManager.flags.EnableTimestampPacket.set(true);
auto &csr = pDevice->getUltCommandStreamReceiver<FamilyType>();
csr.timestampPacketWriteEnabled = true;
MockKernelWithInternals mockKernel(*pDevice, context);
auto mockCmdQ = std::make_unique<MockCommandQueueHw<FamilyType>>(context, pDevice, nullptr);
@@ -1593,9 +1592,8 @@ HWTEST_F(EnqueueKernelTest, givenTimestampPacketWhenEnqueueingNonBlockedThenMake
}
HWTEST_F(EnqueueKernelTest, givenTimestampPacketWhenEnqueueingBlockedThenMakeItResidentOnSubmit) {
DebugManagerStateRestore restore;
DebugManager.flags.EnableTimestampPacket.set(true);
auto &csr = pDevice->getUltCommandStreamReceiver<FamilyType>();
csr.timestampPacketWriteEnabled = true;
MockKernelWithInternals mockKernel(*pDevice, context);
auto mockCmdQ = std::make_unique<MockCommandQueueHw<FamilyType>>(context, pDevice, nullptr);