mirror of
https://github.com/intel/compute-runtime.git
synced 2025-09-15 13:01:45 +08:00
Remove not needed debug variable.
Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
This commit is contained in:

committed by
Compute-Runtime-Automation

parent
a06fbd2077
commit
3162c52250
@ -268,7 +268,6 @@ CFELargeGRFThreadAdjustDisable = -1
|
||||
SynchronizeWalkerInWparidMode = -1
|
||||
EnableWalkerPartition = -1
|
||||
OverrideNumComputeUnitsForScratch = -1
|
||||
ForceWorkgroupSize1x1x1 = -1
|
||||
ForceThreadGroupDispatchSize = -1
|
||||
ForceStatelessL1CachingPolicy = -1
|
||||
ForceMemoryBankIndexOverride = -1
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2021 Intel Corporation
|
||||
* Copyright (C) 2021-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@ -17,88 +17,6 @@ using namespace NEO;
|
||||
|
||||
using XeHPComputeWorkgroupSizeTest = Test<ClDeviceFixture>;
|
||||
|
||||
XEHPTEST_F(XeHPComputeWorkgroupSizeTest, givenXeHPAndForceWorkgroupSize1x1x1FlagWhenComputeWorkgroupSizeIsCalledThenExpectedLwsIsReturned) {
|
||||
DebugManagerStateRestore dbgRestore;
|
||||
|
||||
auto program = std::make_unique<MockProgram>(toClDeviceVector(*pClDevice));
|
||||
|
||||
MockKernelWithInternals mockKernel(*pClDevice);
|
||||
|
||||
GraphicsAllocation localMemoryAllocation(0, GraphicsAllocation::AllocationType::BUFFER, nullptr, 123, 456, 789, MemoryPool::LocalMemory);
|
||||
MockBuffer buffer(localMemoryAllocation);
|
||||
cl_mem clMem = &buffer;
|
||||
auto &kernel = *mockKernel.mockKernel;
|
||||
auto &kernelInfo = mockKernel.kernelInfo;
|
||||
kernelInfo.addArgBuffer(0, 0);
|
||||
kernel.isBuiltIn = true;
|
||||
kernel.initialize();
|
||||
kernel.setArgBuffer(0, sizeof(cl_mem *), &clMem);
|
||||
|
||||
auto hwInfo = pDevice->getRootDeviceEnvironment().getMutableHardwareInfo();
|
||||
const auto &hwInfoConfig = *HwInfoConfig::get(hwInfo->platform.eProductFamily);
|
||||
EXPECT_FALSE(pDevice->isSimulation());
|
||||
|
||||
Vec3<size_t> elws{0, 0, 0};
|
||||
Vec3<size_t> gws{128, 128, 128};
|
||||
Vec3<size_t> offset{0, 0, 0};
|
||||
DispatchInfo dispatchInfo{pClDevice, &kernel, 3, gws, elws, offset};
|
||||
|
||||
{
|
||||
DebugManager.flags.ForceWorkgroupSize1x1x1.set(0);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
{
|
||||
DebugManager.flags.ForceWorkgroupSize1x1x1.set(1);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_EQ(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
{
|
||||
DebugManager.flags.ForceWorkgroupSize1x1x1.set(-1);
|
||||
hwInfo->platform.usRevId = hwInfoConfig.getHwRevIdFromStepping(REVISION_A0, *hwInfo);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
{
|
||||
DebugManager.flags.ForceLocalMemoryAccessMode.set(1);
|
||||
hwInfo->platform.usRevId = hwInfoConfig.getHwRevIdFromStepping(REVISION_A0, *hwInfo);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_EQ(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
DebugManager.flags.ForceLocalMemoryAccessMode.set(-1);
|
||||
}
|
||||
|
||||
{
|
||||
hwInfo->platform.usRevId = hwInfoConfig.getHwRevIdFromStepping(REVISION_B, *hwInfo);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
{
|
||||
hwInfo->platform.usRevId = hwInfoConfig.getHwRevIdFromStepping(REVISION_A0, *hwInfo);
|
||||
hwInfo->featureTable.flags.ftrSimulationMode = true;
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
EXPECT_TRUE(pDevice->isSimulation());
|
||||
}
|
||||
{
|
||||
hwInfo->featureTable.flags.ftrSimulationMode = false;
|
||||
kernel.setAuxTranslationDirection(AuxTranslationDirection::NonAuxToAux);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
{
|
||||
kernelInfo.kernelDescriptor.payloadMappings.explicitArgs.clear();
|
||||
kernelInfo.addArgImage(0, 0);
|
||||
kernel.setAuxTranslationDirection(AuxTranslationDirection::None);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
{
|
||||
kernelInfo.kernelDescriptor.payloadMappings.explicitArgs.clear();
|
||||
kernelInfo.addArgImmediate(0);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
}
|
||||
XEHPTEST_F(XeHPComputeWorkgroupSizeTest, giveXeHpA0WhenKernelIsaIsBelowThresholdAndThereAreNoImageBarriersAndSlmThenSmallWorkgorupSizeIsSelected) {
|
||||
auto program = std::make_unique<MockProgram>(toClDeviceVector(*pClDevice));
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (C) 2021 Intel Corporation
|
||||
# Copyright (C) 2021-2022 Intel Corporation
|
||||
#
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
@ -18,7 +18,6 @@ if(TESTS_XE_HPG_CORE)
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/copy_engine_tests_xe_hpg_core.cpp
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/hw_helper_tests_xe_hpg_core.cpp
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/test_device_caps_xe_hpg_core.cpp
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/test_local_work_size_xe_hpg_core.cpp
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/compute_mode_tests_xe_hpg_core.cpp
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/image_tests_xe_hpg_core.cpp
|
||||
)
|
||||
|
@ -1,63 +0,0 @@
|
||||
/*
|
||||
* Copyright (C) 2021 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#include "shared/source/helpers/hw_helper.h"
|
||||
#include "shared/source/os_interface/hw_info_config.h"
|
||||
#include "shared/test/common/helpers/debug_manager_state_restore.h"
|
||||
#include "shared/test/common/test_macros/test.h"
|
||||
|
||||
#include "opencl/source/command_queue/gpgpu_walker.h"
|
||||
#include "opencl/test/unit_test/fixtures/cl_device_fixture.h"
|
||||
#include "opencl/test/unit_test/mocks/mock_buffer.h"
|
||||
#include "opencl/test/unit_test/mocks/mock_kernel.h"
|
||||
|
||||
using namespace NEO;
|
||||
|
||||
using XeHpgCoreComputeWorkgroupSizeTest = Test<ClDeviceFixture>;
|
||||
XE_HPG_CORETEST_F(XeHpgCoreComputeWorkgroupSizeTest, givenForceWorkgroupSize1x1x1FlagWhenComputeWorkgroupSizeIsCalledThenExpectedLwsIsReturned) {
|
||||
DebugManagerStateRestore dbgRestore;
|
||||
|
||||
auto program = std::make_unique<MockProgram>(toClDeviceVector(*pClDevice));
|
||||
|
||||
MockKernelWithInternals mockKernel(*pClDevice);
|
||||
|
||||
GraphicsAllocation localMemoryAllocation(0, GraphicsAllocation::AllocationType::BUFFER, nullptr, 123, 456, 789, MemoryPool::LocalMemory);
|
||||
MockBuffer buffer(localMemoryAllocation);
|
||||
cl_mem clMem = &buffer;
|
||||
auto &kernel = *mockKernel.mockKernel;
|
||||
auto &kernelInfo = mockKernel.kernelInfo;
|
||||
kernelInfo.addArgBuffer(0, 0);
|
||||
kernel.isBuiltIn = true;
|
||||
kernel.initialize();
|
||||
kernel.setArgBuffer(0, sizeof(cl_mem *), &clMem);
|
||||
|
||||
auto hwInfo = pDevice->getRootDeviceEnvironment().getMutableHardwareInfo();
|
||||
EXPECT_FALSE(pDevice->isSimulation());
|
||||
|
||||
Vec3<size_t> elws{0, 0, 0};
|
||||
Vec3<size_t> gws{128, 128, 128};
|
||||
Vec3<size_t> offset{0, 0, 0};
|
||||
DispatchInfo dispatchInfo{pClDevice, &kernel, 3, gws, elws, offset};
|
||||
const auto &hwInfoConfig = *HwInfoConfig::get(hwInfo->platform.eProductFamily);
|
||||
|
||||
{
|
||||
DebugManager.flags.ForceWorkgroupSize1x1x1.set(0);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
{
|
||||
DebugManager.flags.ForceWorkgroupSize1x1x1.set(1);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_EQ(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
{
|
||||
DebugManager.flags.ForceWorkgroupSize1x1x1.set(-1);
|
||||
hwInfo->platform.usRevId = hwInfoConfig.getHwRevIdFromStepping(REVISION_A0, *hwInfo);
|
||||
auto expectedLws = computeWorkgroupSize(dispatchInfo);
|
||||
EXPECT_NE(1u, expectedLws.x * expectedLws.y * expectedLws.z);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user