Debian Codegraph @

shared/test/unit_test/gen12lp/dg1/test_device_caps_dg1.cpp

raw
1 /*
2 * Copyright (C) 2020-2023 Intel Corporation
3 *
4 * SPDX-License-Identifier: MIT
5 *
6 */
7
8 #include "shared/source/gen12lp/hw_cmds_dg1.h"
9 #include "shared/source/gen12lp/hw_info_dg1.h"
10 #include "shared/test/common/fixtures/device_fixture.h"
11 #include "shared/test/common/mocks/mock_device.h"
12 #include "shared/test/common/test_macros/header/per_product_test_definitions.h"
13 #include "shared/test/common/test_macros/test.h"
14
15 using namespace NEO;
16
17 using Dg1DeviceCaps = Test<DeviceFixture>;
18
19 DG1TEST_F(Dg1DeviceCaps, givenDg1WhenCheckSupportCacheFlushAfterWalkerThenFalse) {
20 EXPECT_TRUE(pDevice->getHardwareInfo().capabilityTable.supportCacheFlushAfterWalker);
21 }
22
23 DG1TEST_F(Dg1DeviceCaps, givenDG1WhenCheckftr64KBpagesThenTrue) {
24 EXPECT_TRUE(pDevice->getHardwareInfo().capabilityTable.ftr64KBpages);
25 }
26
27 DG1TEST_F(Dg1DeviceCaps, givenDG1WhenRequestedVmeFlagsThenReturnFalse) {
28 EXPECT_FALSE(pDevice->getHardwareInfo().capabilityTable.supportsVme);
29 EXPECT_FALSE(pDevice->getHardwareInfo().capabilityTable.ftrSupportsVmeAvcTextureSampler);
30 EXPECT_FALSE(pDevice->getHardwareInfo().capabilityTable.ftrSupportsVmeAvcPreemption);
31 }
32
33 DG1TEST_F(Dg1DeviceCaps, givenDg1WhenCheckFtrSupportsInteger64BitAtomicsThenReturnTrue) {
34 EXPECT_TRUE(pDevice->getHardwareInfo().capabilityTable.ftrSupportsInteger64BitAtomics);
35 }
36
37 DG1TEST_F(Dg1DeviceCaps, givenDg1WhenCheckGpuAddressSpaceThenReturn47bits) {
38 EXPECT_EQ(MemoryConstants::max64BitAppAddress, pDevice->getHardwareInfo().capabilityTable.gpuAddressSpace);
39 }