mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-25 21:42:53 +08:00
Altered unit tests to suit new MiFlushDwWA() workaround.
Related-To: NEO-4426 Change-Id: Ib13719a711adda6fb3da3c2893898f0f31418508
This commit is contained in:
committed by
sys_ocldev
parent
c1aabdf51c
commit
6eae7fc3c7
@@ -8,6 +8,7 @@
|
||||
#include "shared/source/command_container/command_encoder.h"
|
||||
|
||||
#include "opencl/test/unit_test/fixtures/device_fixture.h"
|
||||
#include "opencl/test/unit_test/helpers/unit_test_helper.h"
|
||||
#include "test.h"
|
||||
|
||||
using namespace NEO;
|
||||
@@ -37,7 +38,19 @@ HWTEST_F(CommandEncoderTests, givenImmDataWriteWhenProgrammingMiFlushDwThenSetAl
|
||||
EncodeMiFlushDW<FamilyType>::programMiFlushDw(linearStream, gpuAddress, immData);
|
||||
auto miFlushDwCmd = reinterpret_cast<MI_FLUSH_DW *>(buffer);
|
||||
|
||||
EXPECT_EQ(sizeof(MI_FLUSH_DW), linearStream.getUsed());
|
||||
unsigned int sizeMultiplier = 1;
|
||||
if (UnitTestHelper<FamilyType>::additionalMiFlushDwRequired) {
|
||||
sizeMultiplier = 2;
|
||||
uint64_t gpuAddress = 0x0;
|
||||
uint64_t immData = 0;
|
||||
|
||||
EXPECT_EQ(MI_FLUSH_DW::POST_SYNC_OPERATION_NO_WRITE, miFlushDwCmd->getPostSyncOperation());
|
||||
EXPECT_EQ(gpuAddress, miFlushDwCmd->getDestinationAddress());
|
||||
EXPECT_EQ(immData, miFlushDwCmd->getImmediateData());
|
||||
miFlushDwCmd++;
|
||||
}
|
||||
|
||||
EXPECT_EQ(sizeMultiplier * sizeof(MI_FLUSH_DW), linearStream.getUsed());
|
||||
EXPECT_EQ(MI_FLUSH_DW::POST_SYNC_OPERATION_WRITE_IMMEDIATE_DATA_QWORD, miFlushDwCmd->getPostSyncOperation());
|
||||
EXPECT_EQ(gpuAddress, miFlushDwCmd->getDestinationAddress());
|
||||
EXPECT_EQ(immData, miFlushDwCmd->getImmediateData());
|
||||
|
||||
Reference in New Issue
Block a user