Remove device enqueue part 14

- rename not proper structs

Related-To: NEO-6559
Signed-off-by: Katarzyna Cencelewska <katarzyna.cencelewska@intel.com>
This commit is contained in:
Katarzyna Cencelewska
2022-01-31 16:30:36 +00:00
committed by Compute-Runtime-Automation
parent f45fadf89b
commit 73f8d9e3ed
9 changed files with 28 additions and 107 deletions

View File

@ -118,7 +118,6 @@ class ClDevice : public BaseObject<_cl_device_id> {
const std::string &peekCompilerExtensions() const;
const std::string &peekCompilerExtensionsWithFeatures() const;
DeviceBitfield getDeviceBitfield() const;
bool isDeviceEnqueueSupported() const;
bool arePipesSupported() const;
bool isPciBusInfoValid() const;

View File

@ -401,7 +401,6 @@ set(TEST_KERNEL_2_0_options
)
set(TEST_KERNEL_2_0
test_files/simple_block_kernel.cl
test_files/simple_nonuniform.cl
)
@ -454,7 +453,6 @@ set(TEST_KERNEL_PRINTF_internal_options_gen9lp
file(GLOB_RECURSE TEST_KERNELS test_files/*.cl)
list(REMOVE_ITEM TEST_KERNELS "${CMAKE_CURRENT_SOURCE_DIR}/test_files/shouldfail.cl")
list(REMOVE_ITEM TEST_KERNELS "${CMAKE_CURRENT_SOURCE_DIR}/test_files/valid_kernel.cl")
list(REMOVE_ITEM TEST_KERNELS "${CMAKE_CURRENT_SOURCE_DIR}/test_files/simple_block_kernel.cl")
list(REMOVE_ITEM TEST_KERNELS "${CMAKE_CURRENT_SOURCE_DIR}/test_files/simple_nonuniform.cl")
list(REMOVE_ITEM TEST_KERNELS "${CMAKE_CURRENT_SOURCE_DIR}/test_files/stateless_kernel.cl")
list(REMOVE_ITEM TEST_KERNELS ${TEST_KERNEL_VME})

View File

@ -717,9 +717,9 @@ TEST(DeviceGetEngineTest, givenNonHwCsrModeWhenGetEngineThenDefaultEngineIsRetur
EXPECT_EQ(defaultEngine.commandStreamReceiver, internalEngine.commandStreamReceiver);
}
using DeviceQueueFamiliesTests = ::testing::Test;
using QueueFamiliesTests = ::testing::Test;
HWTEST_F(DeviceQueueFamiliesTests, whenGettingQueueFamilyCapabilitiesAllThenReturnCorrectValue) {
HWTEST_F(QueueFamiliesTests, whenGettingQueueFamilyCapabilitiesAllThenReturnCorrectValue) {
const cl_command_queue_capabilities_intel expectedProperties = CL_QUEUE_CAPABILITY_CREATE_SINGLE_QUEUE_EVENTS_INTEL |
CL_QUEUE_CAPABILITY_CREATE_CROSS_QUEUE_EVENTS_INTEL |
CL_QUEUE_CAPABILITY_SINGLE_QUEUE_EVENT_WAIT_LIST_INTEL |
@ -739,13 +739,13 @@ HWTEST_F(DeviceQueueFamiliesTests, whenGettingQueueFamilyCapabilitiesAllThenRetu
EXPECT_EQ(expectedProperties, MockClDevice::getQueueFamilyCapabilitiesAll());
}
HWTEST_F(DeviceQueueFamiliesTests, givenComputeQueueWhenGettingQueueFamilyCapabilitiesThenReturnDefaultCapabilities) {
HWTEST_F(QueueFamiliesTests, givenComputeQueueWhenGettingQueueFamilyCapabilitiesThenReturnDefaultCapabilities) {
auto device = std::make_unique<MockClDevice>(MockDevice::createWithNewExecutionEnvironment<MockDevice>(defaultHwInfo.get()));
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, device->getQueueFamilyCapabilities(NEO::EngineGroupType::Compute));
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, device->getQueueFamilyCapabilities(NEO::EngineGroupType::RenderCompute));
}
HWCMDTEST_F(IGFX_GEN8_CORE, DeviceQueueFamiliesTests, givenCopyQueueWhenGettingQueueFamilyCapabilitiesThenDoNotReturnUnsupportedOperations) {
HWCMDTEST_F(IGFX_GEN8_CORE, QueueFamiliesTests, givenCopyQueueWhenGettingQueueFamilyCapabilitiesThenDoNotReturnUnsupportedOperations) {
const cl_command_queue_capabilities_intel capabilitiesNotSupportedOnBlitter = CL_QUEUE_CAPABILITY_KERNEL_INTEL |
CL_QUEUE_CAPABILITY_FILL_BUFFER_INTEL |
CL_QUEUE_CAPABILITY_TRANSFER_IMAGE_INTEL |

View File

@ -1,76 +0,0 @@
/*
* Copyright (C) 2018-2021 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
void block_fn(size_t tid, int mul, __global int* res)
{
res[tid] = mul * 7 - 21;
}
kernel void simple_block_kernel(__global int* res)
{
int multiplier = 3;
size_t tid = get_global_id(0);
void (^kernelBlock)(void) = ^{ block_fn(tid, multiplier, res); };
res[tid] = -1;
queue_t def_q = get_default_queue();
ndrange_t ndrange = ndrange_1D(1);
int enq_res = enqueue_kernel(def_q, CLK_ENQUEUE_FLAGS_WAIT_KERNEL, ndrange, kernelBlock);
if(enq_res != CLK_SUCCESS) { res[tid] = -1; return; }
}
void block_reflection(ulong scalar, __global uint* buffer, read_only image3d_t img, sampler_t sampler)
{
float4 color;
int4 coord;
buffer[0] = scalar;
coord.x = scalar;
coord.y = 0;
coord.z = 0;
int width = get_image_width( img );
int heigth = get_image_height( img );
int depth = get_image_depth( img );
int order = get_image_channel_order( img );
int type = get_image_channel_data_type( img );
color = read_imagef( img, sampler, coord );
buffer[1] = (uint)color.x;
buffer[2] = (uint)width;
buffer[3] = (uint)heigth;
buffer[4] = (uint)depth;
buffer[5] = (uint)order;
buffer[6] = (uint)type;
sampler_t samplerA = CLK_NORMALIZED_COORDS_TRUE | CLK_ADDRESS_CLAMP_TO_EDGE | CLK_FILTER_NEAREST;
color = read_imagef( img, samplerA, coord );
buffer[7] = (uint)color.y;
queue_t def_q = get_default_queue();
ndrange_t ndrange = ndrange_1D(1);
if( scalar > 2 ){
scalar--;
int enq_res = enqueue_kernel(def_q, CLK_ENQUEUE_FLAGS_WAIT_KERNEL, ndrange, ^{block_reflection(scalar, buffer, img, sampler);});
}
}
kernel void kernel_reflection(sampler_t sampler, read_only image3d_t img, __global uint* buffer, ulong scalar)
{
size_t tid = get_global_id(0);
void (^kernelBlock)(void) = ^{ block_reflection(scalar, buffer, img, sampler); };
queue_t def_q = get_default_queue();
ndrange_t ndrange = ndrange_1D(1);
if( scalar > 0 ){
int enq_res = enqueue_kernel(def_q, CLK_ENQUEUE_FLAGS_WAIT_KERNEL, ndrange, kernelBlock);
if(enq_res != CLK_SUCCESS) { buffer[2] = 1; }
}
}