mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
specialization constant test fixes (#927)
* remove SPV_KHR_no_integer_wrap_decoration * address review comments * remove the assemble_spirv script There is another PR in flight that adds a much more complete script that we should merge instead.
This commit is contained in:
@@ -7,7 +7,6 @@
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int8
|
||||
OpExtension "SPV_KHR_no_integer_wrap_decoration"
|
||||
%1 = OpExtInstImport "OpenCL.std"
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %11 "spec_const_kernel"
|
||||
@@ -21,7 +20,6 @@
|
||||
OpName %if_end "if.end"
|
||||
OpDecorate %test_value FuncParamAttr Zext
|
||||
OpDecorate %test_value LinkageAttributes "test_value" Export
|
||||
OpDecorate %add NoSignedWrap
|
||||
OpDecorate %false SpecId 101
|
||||
%uchar = OpTypeInt 8 0
|
||||
%uint = OpTypeInt 32 0
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int8
|
||||
OpExtension "SPV_KHR_no_integer_wrap_decoration"
|
||||
%1 = OpExtInstImport "OpenCL.std"
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %11 "spec_const_kernel"
|
||||
@@ -21,7 +20,6 @@
|
||||
OpName %if_end "if.end"
|
||||
OpDecorate %test_value FuncParamAttr Zext
|
||||
OpDecorate %test_value LinkageAttributes "test_value" Export
|
||||
OpDecorate %add NoSignedWrap
|
||||
OpDecorate %false SpecId 101
|
||||
%uchar = OpTypeInt 8 0
|
||||
%uint = OpTypeInt 32 0
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int8
|
||||
OpExtension "SPV_KHR_no_integer_wrap_decoration"
|
||||
%1 = OpExtInstImport "OpenCL.std"
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %11 "spec_const_kernel"
|
||||
@@ -21,7 +20,6 @@
|
||||
OpName %if_end "if.end"
|
||||
OpDecorate %test_value FuncParamAttr Zext
|
||||
OpDecorate %test_value LinkageAttributes "test_value" Export
|
||||
OpDecorate %add NoSignedWrap
|
||||
OpDecorate %true SpecId 101
|
||||
%uchar = OpTypeInt 8 0
|
||||
%uint = OpTypeInt 32 0
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
OpCapability Linkage
|
||||
OpCapability Kernel
|
||||
OpCapability Int8
|
||||
OpExtension "SPV_KHR_no_integer_wrap_decoration"
|
||||
%1 = OpExtInstImport "OpenCL.std"
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %11 "spec_const_kernel"
|
||||
@@ -21,7 +20,6 @@
|
||||
OpName %if_end "if.end"
|
||||
OpDecorate %test_value FuncParamAttr Zext
|
||||
OpDecorate %test_value LinkageAttributes "test_value" Export
|
||||
OpDecorate %add NoSignedWrap
|
||||
OpDecorate %true SpecId 101
|
||||
%uchar = OpTypeInt 8 0
|
||||
%uint = OpTypeInt 32 0
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
OpCapability Addresses
|
||||
OpCapability Kernel
|
||||
OpCapability Int8
|
||||
OpExtension "SPV_KHR_no_integer_wrap_decoration"
|
||||
%1 = OpExtInstImport "OpenCL.std"
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %9 "spec_const_kernel"
|
||||
@@ -18,7 +17,6 @@
|
||||
OpName %add "add"
|
||||
OpDecorate %spec_const_kernel_spec_constant_value Constant
|
||||
OpDecorate %spec_const_kernel_spec_constant_value Alignment 1
|
||||
OpDecorate %add NoSignedWrap
|
||||
OpDecorate %uchar_0 SpecId 101
|
||||
%uchar = OpTypeInt 8 0
|
||||
%uint = OpTypeInt 32 0
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
OpCapability Addresses
|
||||
OpCapability Kernel
|
||||
OpCapability Int8
|
||||
OpExtension "SPV_KHR_no_integer_wrap_decoration"
|
||||
%1 = OpExtInstImport "OpenCL.std"
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %9 "spec_const_kernel"
|
||||
@@ -18,7 +17,6 @@
|
||||
OpName %add "add"
|
||||
OpDecorate %spec_const_kernel_spec_constant_value Constant
|
||||
OpDecorate %spec_const_kernel_spec_constant_value Alignment 1
|
||||
OpDecorate %add NoSignedWrap
|
||||
OpDecorate %uchar_0 SpecId 101
|
||||
%uchar = OpTypeInt 8 0
|
||||
%uint = OpTypeInt 32 0
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
OpCapability Addresses
|
||||
OpCapability Kernel
|
||||
OpCapability Int16
|
||||
OpExtension "SPV_KHR_no_integer_wrap_decoration"
|
||||
%1 = OpExtInstImport "OpenCL.std"
|
||||
OpMemoryModel Physical32 OpenCL
|
||||
OpEntryPoint Kernel %9 "spec_const_kernel"
|
||||
@@ -17,7 +16,6 @@
|
||||
OpName %entry "entry"
|
||||
OpDecorate %spec_const_kernel_spec_constant_value Constant
|
||||
OpDecorate %spec_const_kernel_spec_constant_value Alignment 2
|
||||
OpDecorate %add NoSignedWrap
|
||||
OpDecorate %ushort_0 SpecId 101
|
||||
%ushort = OpTypeInt 16 0
|
||||
%uint = OpTypeInt 32 0
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
OpCapability Addresses
|
||||
OpCapability Kernel
|
||||
OpCapability Int16
|
||||
OpExtension "SPV_KHR_no_integer_wrap_decoration"
|
||||
%1 = OpExtInstImport "OpenCL.std"
|
||||
OpMemoryModel Physical64 OpenCL
|
||||
OpEntryPoint Kernel %9 "spec_const_kernel"
|
||||
@@ -17,7 +16,6 @@
|
||||
OpName %entry "entry"
|
||||
OpDecorate %spec_const_kernel_spec_constant_value Constant
|
||||
OpDecorate %spec_const_kernel_spec_constant_value Alignment 2
|
||||
OpDecorate %add NoSignedWrap
|
||||
OpDecorate %ushort_0 SpecId 101
|
||||
%ushort = OpTypeInt 16 0
|
||||
%uint = OpTypeInt 32 0
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -20,8 +20,7 @@ Agreement as executed between Khronos and the recipient.
|
||||
template <typename T>
|
||||
int run_case(cl_device_id deviceID, cl_context context, cl_command_queue queue,
|
||||
const char *name, T init_buffer, T spec_constant_value,
|
||||
T final_value, bool use_spec_constant,
|
||||
bool (*notEqual)(const T &, const T &) = isNotEqual<T>)
|
||||
T final_value, bool use_spec_constant)
|
||||
{
|
||||
clProgramWrapper prog;
|
||||
cl_int err = CL_SUCCESS;
|
||||
@@ -54,7 +53,6 @@ int run_case(cl_device_id deviceID, cl_context context, cl_command_queue queue,
|
||||
err = clEnqueueNDRangeKernel(queue, kernel, 1, NULL, &work_size, NULL, 0,
|
||||
NULL, NULL);
|
||||
SPIRV_CHECK_ERROR(err, "Failed to enqueue kernel");
|
||||
clFinish(queue);
|
||||
|
||||
T device_results = 0;
|
||||
err = clEnqueueReadBuffer(queue, output_buffer, CL_TRUE, 0, bytes,
|
||||
|
||||
Reference in New Issue
Block a user