From d4e9f3a4eeb79775f703e4be3ebbd93a9afed5ec Mon Sep 17 00:00:00 2001 From: Petr Kurapov Date: Sat, 22 Mar 2025 17:15:38 +0000 Subject: [PATCH 1/3] Add test plan for sycl_ext_intel_kernel_queries extension --- sycl/test-e2e/KernelQueries/test_plan.md | 53 ++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 sycl/test-e2e/KernelQueries/test_plan.md diff --git a/sycl/test-e2e/KernelQueries/test_plan.md b/sycl/test-e2e/KernelQueries/test_plan.md new file mode 100644 index 0000000000000..2f685f8f0c2e6 --- /dev/null +++ b/sycl/test-e2e/KernelQueries/test_plan.md @@ -0,0 +1,53 @@ +# Test plan for [`sycl ext intel kernel queries`][spec-link] extension + +## Testing scope + +### Device coverage + +The unit tests should be launched on every supported device configuration we +have. + +### Type coverage + +Each query is templated on a single template type argument `Param` +with some queries being template overloads of each other. +Each query has a restriction on the value of `Param` defined +in the relevant section of the spec. +Each `Param` defines a related sycl aspect that signals whether the device +supports it. + +Param must be one of the following types defined in +`sycl::ext::intel::info::kernel_device_specific` namespace: +- `spill_memory_size` + +The tests should cover all of these types. + +## Tests + +### Unit tests + +#### Interface tests + +These tests are intended to check that all classes and methods defined by the +extension have correct implementation, i.e.: right signatures, right return +types, all necessary constraints are checked/enforced, etc. + +These tests should check the following: + +- that each query is not available when the template argument `Param` has + a value different than the one in the spec. +- that each query can be called with the appropriate value for `Param` and the + appropriate argument types as defined by its signature. +- the return types of all queries match the spec. + +Tests in this category may not perform some useful actions to exercise the +extension functionality in full, but instead they are focused on making sure +that all APIs are consistent with respect to other APIs. + +#### Check behavior in the case of unsupported aspects + +Verigy that a synchronous `exception` with the error code +`errc::feature_not_supported` is thrown if an aspect is not supported by the +device. + +[spec-link]: https://github.com/intel/llvm/blob/sycl/sycl/doc/extensions/supported/sycl_ext_intel_kernel_queries.asciidoc From b452c3459619604c9d9c42310bcf9b8e55cacb84 Mon Sep 17 00:00:00 2001 From: Petr Kurapov Date: Wed, 26 Mar 2025 10:48:52 +0000 Subject: [PATCH 2/3] Move the test plan to unittests --- sycl/{test-e2e => unittests}/KernelQueries/test_plan.md | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename sycl/{test-e2e => unittests}/KernelQueries/test_plan.md (100%) diff --git a/sycl/test-e2e/KernelQueries/test_plan.md b/sycl/unittests/KernelQueries/test_plan.md similarity index 100% rename from sycl/test-e2e/KernelQueries/test_plan.md rename to sycl/unittests/KernelQueries/test_plan.md From 289de306e4cb6ffeae7c1be18cc8105a5c4a128f Mon Sep 17 00:00:00 2001 From: Petr Kurapov Date: Wed, 26 Mar 2025 10:57:02 +0000 Subject: [PATCH 3/3] Move the plan to extensions --- sycl/unittests/{ => Extensions}/KernelQueries/test_plan.md | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename sycl/unittests/{ => Extensions}/KernelQueries/test_plan.md (100%) diff --git a/sycl/unittests/KernelQueries/test_plan.md b/sycl/unittests/Extensions/KernelQueries/test_plan.md similarity index 100% rename from sycl/unittests/KernelQueries/test_plan.md rename to sycl/unittests/Extensions/KernelQueries/test_plan.md