From 29976f1979bf927a04130f72059458d10de205d2 Mon Sep 17 00:00:00 2001 From: Aaron Greig Date: Thu, 19 Sep 2024 18:03:20 +0100 Subject: [PATCH] Fix most or possibly all match file issues. --- scripts/core/device.yml | 2 +- .../device/device_adapter_cuda.match | 1 + .../device/device_adapter_native_cpu.match | 3 +++ .../kernel/kernel_adapter_opencl.match | 1 - .../program/program_adapter_cuda.match | 2 -- test/conformance/usm/urUSMGetMemAllocInfo.cpp | 19 +++++++++---------- 6 files changed, 14 insertions(+), 14 deletions(-) diff --git a/scripts/core/device.yml b/scripts/core/device.yml index 6ef43ed0ee..d343173f90 100644 --- a/scripts/core/device.yml +++ b/scripts/core/device.yml @@ -200,7 +200,7 @@ etors: - name: VENDOR_ID desc: "[uint32_t] vendor Id of the device" - name: DEVICE_ID - desc: "[uint32_t] Id of the device" + desc: "[uint32_t][optional-query] Id of the device" - name: MAX_COMPUTE_UNITS desc: "[uint32_t] the number of compute units" - name: MAX_WORK_ITEM_DIMENSIONS diff --git a/test/conformance/device/device_adapter_cuda.match b/test/conformance/device/device_adapter_cuda.match index ce2e071f36..37c6233603 100644 --- a/test/conformance/device/device_adapter_cuda.match +++ b/test/conformance/device/device_adapter_cuda.match @@ -1,3 +1,4 @@ {{NONDETERMINISTIC}} urDeviceCreateWithNativeHandleTest.SuccessWithUnOwnedNativeHandle {{OPT}}urDeviceGetGlobalTimestampTest.SuccessSynchronizedTime +urDeviceGetInfoTest.Success/UR_DEVICE_INFO_MAX_READ_WRITE_IMAGE_ARGS diff --git a/test/conformance/device/device_adapter_native_cpu.match b/test/conformance/device/device_adapter_native_cpu.match index b2f88f3bc8..ec17f5d0b7 100644 --- a/test/conformance/device/device_adapter_native_cpu.match +++ b/test/conformance/device/device_adapter_native_cpu.match @@ -28,4 +28,7 @@ urDeviceGetInfoTest.Success/UR_DEVICE_INFO_MAX_WORK_GROUPS_3D urDeviceGetInfoTest.Success/UR_DEVICE_INFO_ASYNC_BARRIER urDeviceGetInfoTest.Success/UR_DEVICE_INFO_HOST_PIPE_READ_WRITE_SUPPORTED urDeviceGetInfoTest.Success/UR_DEVICE_INFO_MAX_REGISTERS_PER_WORK_GROUP +urDeviceGetInfoTest.Success/UR_DEVICE_INFO_ATOMIC_FENCE_SCOPE_CAPABILITIES +urDeviceGetInfoTest.Success/UR_DEVICE_INFO_ATOMIC_MEMORY_SCOPE_CAPABILITIES +urDeviceGetInfoTest.Success/UR_DEVICE_INFO_IP_VERSION urDeviceGetInfoTest.Success/UR_DEVICE_INFO_KERNEL_SET_SPECIALIZATION_CONSTANTS diff --git a/test/conformance/kernel/kernel_adapter_opencl.match b/test/conformance/kernel/kernel_adapter_opencl.match index d65c8e51c8..8a0fe2b491 100644 --- a/test/conformance/kernel/kernel_adapter_opencl.match +++ b/test/conformance/kernel/kernel_adapter_opencl.match @@ -1,2 +1 @@ {{NONDETERMINISTIC}} -urKernelGetInfoTest.Success/Intel_R__OpenCL_{{.*}}_UR_KERNEL_INFO_NUM_REGS diff --git a/test/conformance/program/program_adapter_cuda.match b/test/conformance/program/program_adapter_cuda.match index 4e9d452f44..b593618a91 100644 --- a/test/conformance/program/program_adapter_cuda.match +++ b/test/conformance/program/program_adapter_cuda.match @@ -6,8 +6,6 @@ urProgramBuildTest.BuildFailure/NVIDIA_CUDA_BACKEND___{{.*}}_ # This test flakily fails {{OPT}}urProgramGetBuildInfoSingleTest.LogIsNullTerminated/NVIDIA_CUDA_BACKEND___{{.*}} # CUDA doesn't expose kernel numbers or names -urProgramGetInfoTest.Success/NVIDIA_CUDA_BACKEND___{{.*}}___UR_PROGRAM_INFO_NUM_KERNELS -urProgramGetInfoTest.Success/NVIDIA_CUDA_BACKEND___{{.*}}___UR_PROGRAM_INFO_KERNEL_NAMES {{OPT}}urProgramSetSpecializationConstantsTest.Success/NVIDIA_CUDA_BACKEND___{{.*}} {{OPT}}urProgramSetSpecializationConstantsTest.UseDefaultValue/NVIDIA_CUDA_BACKEND___{{.*}} urProgramSetMultipleSpecializationConstantsTest.MultipleCalls/NVIDIA_CUDA_BACKEND___{{.*}} diff --git a/test/conformance/usm/urUSMGetMemAllocInfo.cpp b/test/conformance/usm/urUSMGetMemAllocInfo.cpp index 328a0a524b..093cce671c 100644 --- a/test/conformance/usm/urUSMGetMemAllocInfo.cpp +++ b/test/conformance/usm/urUSMGetMemAllocInfo.cpp @@ -3,10 +3,9 @@ // See LICENSE.TXT // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -#include #include -struct urUSMAllocInfoTest +struct urUSMGetMemAllocInfoTest : uur::urUSMDeviceAllocTestWithParam { void SetUp() override { use_pool = getParam() == UR_USM_ALLOC_INFO_POOL; @@ -15,7 +14,7 @@ struct urUSMAllocInfoTest } }; -UUR_TEST_SUITE_P(urUSMAllocInfoTest, +UUR_TEST_SUITE_P(urUSMGetMemAllocInfoTest, ::testing::Values(UR_USM_ALLOC_INFO_TYPE, UR_USM_ALLOC_INFO_BASE_PTR, UR_USM_ALLOC_INFO_SIZE, @@ -31,7 +30,7 @@ static std::unordered_map usm_info_size_map = { {UR_USM_ALLOC_INFO_POOL, sizeof(ur_usm_pool_handle_t)}, }; -TEST_P(urUSMAllocInfoTest, Success) { +TEST_P(urUSMGetMemAllocInfoTest, Success) { size_t size = 0; auto alloc_info = getParam(); ASSERT_QUERY_SUCCESS( @@ -81,10 +80,10 @@ TEST_P(urUSMAllocInfoTest, Success) { } } -using urUSMGetMemAllocInfoTest = uur::urUSMDeviceAllocTest; -UUR_INSTANTIATE_DEVICE_TEST_SUITE_P(urUSMGetMemAllocInfoTest); +using urUSMGetMemAllocInfoNegativeTest = uur::urUSMDeviceAllocTest; +UUR_INSTANTIATE_DEVICE_TEST_SUITE_P(urUSMGetMemAllocInfoNegativeTest); -TEST_P(urUSMGetMemAllocInfoTest, InvalidNullHandleContext) { +TEST_P(urUSMGetMemAllocInfoNegativeTest, InvalidNullHandleContext) { ur_usm_type_t USMType; ASSERT_EQ_RESULT(UR_RESULT_ERROR_INVALID_NULL_HANDLE, urUSMGetMemAllocInfo(nullptr, ptr, UR_USM_ALLOC_INFO_TYPE, @@ -92,7 +91,7 @@ TEST_P(urUSMGetMemAllocInfoTest, InvalidNullHandleContext) { nullptr)); } -TEST_P(urUSMGetMemAllocInfoTest, InvalidNullPointerMem) { +TEST_P(urUSMGetMemAllocInfoNegativeTest, InvalidNullPointerMem) { ur_usm_type_t USMType; ASSERT_EQ_RESULT( UR_RESULT_ERROR_INVALID_NULL_POINTER, @@ -100,7 +99,7 @@ TEST_P(urUSMGetMemAllocInfoTest, InvalidNullPointerMem) { sizeof(ur_usm_type_t), &USMType, nullptr)); } -TEST_P(urUSMGetMemAllocInfoTest, InvalidEnumeration) { +TEST_P(urUSMGetMemAllocInfoNegativeTest, InvalidEnumeration) { ur_usm_type_t USMType; ASSERT_EQ_RESULT( UR_RESULT_ERROR_INVALID_ENUMERATION, @@ -108,7 +107,7 @@ TEST_P(urUSMGetMemAllocInfoTest, InvalidEnumeration) { sizeof(ur_usm_type_t), &USMType, nullptr)); } -TEST_P(urUSMGetMemAllocInfoTest, InvalidValuePropSize) { +TEST_P(urUSMGetMemAllocInfoNegativeTest, InvalidValuePropSize) { ur_usm_type_t USMType; ASSERT_EQ_RESULT(UR_RESULT_ERROR_INVALID_SIZE, urUSMGetMemAllocInfo(context, ptr, UR_USM_ALLOC_INFO_TYPE,