mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
cl20: Khronos Bug 16080 Fix local work size limit.
Problem: Some tests assume that all local work-items can be used in a single dimension of an NDRange. Spec References: OpenCL C 2.0 r19, table 4.3, CL_DEVICE_MAX_WORK_ITEM_SIZES. Solution: The overall maximum local work size is trimmed to that of an NDRange's first dimension or all dimensions, as appropriate. Test Suite Affected: atomics, non_uniform_work_group, and workgroups. Side Effects: None Change-Id: I2e8179ca15c2c090f47ea84d1d3c109dd69ec185
This commit is contained in:
committed by
Kévin Petit
parent
e0d7ab2187
commit
627c180a31
@@ -205,6 +205,12 @@ int test_atomic_function(cl_device_id deviceID, cl_context context, cl_command_q
|
||||
error = clGetKernelWorkGroupInfo( kernel, deviceID, CL_KERNEL_WORK_GROUP_SIZE, sizeof( workSize ), &workSize, NULL );
|
||||
test_error( error, "Unable to obtain max work group size for device and kernel combo" );
|
||||
|
||||
// "workSize" is limited to that of the first dimension as only a 1DRange is executed.
|
||||
if( maxSizes[0] < workSize )
|
||||
{
|
||||
workSize = maxSizes[0];
|
||||
}
|
||||
|
||||
threadSize = groupSize = workSize;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user