Skip to content

Commit d1434ae

Browse files
authored
Added new cl_khr_semaphore tests to verify clCreateSemaphoreWithPropertiesKHR negative results (#1962)
According to work plan from #1691, new clSemaphoreWrapper introduced to avoid duplication of code
1 parent 3c81548 commit d1434ae

File tree

4 files changed

+720
-0
lines changed

4 files changed

+720
-0
lines changed

test_conformance/extensions/cl_khr_semaphore/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ set(${MODULE_NAME}_SOURCES
66
test_semaphores_negative_release_retain.cpp
77
test_semaphores_negative_getinfo.cpp
88
test_semaphores_negative_wait.cpp
9+
test_semaphores_negative_create.cpp
910
semaphore_base.h
1011
)
1112

test_conformance/extensions/cl_khr_semaphore/main.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,17 @@ test_definition test_list[] = {
3535
ADD_TEST_VERSION(semaphores_multi_wait, Version(1, 2)),
3636
ADD_TEST_VERSION(semaphores_queries, Version(1, 2)),
3737
ADD_TEST_VERSION(semaphores_import_export_fd, Version(1, 2)),
38+
ADD_TEST_VERSION(semaphores_negative_create_invalid_context, Version(1, 2)),
39+
ADD_TEST_VERSION(semaphores_negative_create_invalid_property,
40+
Version(1, 2)),
41+
ADD_TEST_VERSION(semaphores_negative_create_multi_device_property,
42+
Version(1, 2)),
43+
ADD_TEST_VERSION(semaphores_negative_create_invalid_device, Version(1, 2)),
44+
ADD_TEST_VERSION(semaphores_negative_create_import_invalid_device,
45+
Version(1, 2)),
46+
ADD_TEST_VERSION(semaphores_negative_create_invalid_value, Version(1, 2)),
47+
ADD_TEST_VERSION(semaphores_negative_create_invalid_operation,
48+
Version(1, 2)),
3849
ADD_TEST_VERSION(semaphores_negative_get_info_invalid_semaphore,
3950
Version(1, 2)),
4051
ADD_TEST_VERSION(semaphores_negative_get_info_invalid_value, Version(1, 2)),

test_conformance/extensions/cl_khr_semaphore/procs.h

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,28 @@ extern int test_semaphores_import_export_fd(cl_device_id deviceID,
4545
cl_context context,
4646
cl_command_queue queue,
4747
int num_elements);
48+
extern int test_semaphores_negative_create_invalid_context(
49+
cl_device_id device, cl_context context, cl_command_queue queue,
50+
int num_elements);
51+
extern int test_semaphores_negative_create_invalid_property(
52+
cl_device_id device, cl_context context, cl_command_queue queue,
53+
int num_elements);
54+
extern int test_semaphores_negative_create_multi_device_property(
55+
cl_device_id device, cl_context context, cl_command_queue queue,
56+
int num_elements);
57+
extern int test_semaphores_negative_create_invalid_device(
58+
cl_device_id device, cl_context context, cl_command_queue queue,
59+
int num_elements);
60+
extern int test_semaphores_negative_create_import_invalid_device(
61+
cl_device_id device, cl_context context, cl_command_queue queue,
62+
int num_elements);
63+
extern int test_semaphores_negative_create_invalid_value(cl_device_id device,
64+
cl_context context,
65+
cl_command_queue queue,
66+
int num_elements);
67+
extern int test_semaphores_negative_create_invalid_operation(
68+
cl_device_id device, cl_context context, cl_command_queue queue,
69+
int num_elements);
4870
extern int test_semaphores_negative_get_info_invalid_semaphore(
4971
cl_device_id device, cl_context context, cl_command_queue queue,
5072
int num_elements);

0 commit comments

Comments
 (0)