mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
Remove unnecessary cl_mem_flags casts (#1018)
* api, atomics: remove unnecessary cl_mem_flags casts Instances in api, atomics, buffers and c11_atomics suites Contributes #759 Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> * basic: remove unnecessary cl_mem_flags casts Contributes #759 Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> * spir, thread_dimensions: remove unnecessary cl_mem_flags casts Instances in spir, thread_dimensions and workgroups tests Contributes #759 Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> * profiling, relationals: remove unnecessary cl_mem_flags casts Includes relationals, profiling, muliple_device_context, integer_ops tests Contributes #759 Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> * clcpp: remove unnecessary cl_mem_flags casts Contibutes #759 Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> * events, geometrics: remove unnecessary cl_mem_flags casts Includes events, geometrics, gl and images tests Contributes #759 Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> * commonfs, compiler: remove unnecessary cl_mem_flags casts Includes cast removal in commonfs, compiler and device_partition tests Fixes #759 Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> * Fix up formatting Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
This commit is contained in:
@@ -210,19 +210,22 @@ int test_geom_cross_double(cl_device_id deviceID, cl_context context, cl_command
|
||||
}
|
||||
fillWithTrickyNumbers_double( inDataA, inDataB, vecsize );
|
||||
|
||||
streams[0] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_COPY_HOST_PTR), bufSize, inDataA, NULL);
|
||||
streams[0] = clCreateBuffer(context, CL_MEM_COPY_HOST_PTR, bufSize,
|
||||
inDataA, NULL);
|
||||
if( streams[0] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating input array A failed!\n");
|
||||
return -1;
|
||||
}
|
||||
streams[1] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_COPY_HOST_PTR), bufSize, inDataB, NULL);
|
||||
streams[1] = clCreateBuffer(context, CL_MEM_COPY_HOST_PTR, bufSize,
|
||||
inDataB, NULL);
|
||||
if( streams[1] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating input array B failed!\n");
|
||||
return -1;
|
||||
}
|
||||
streams[2] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_READ_WRITE), bufSize, NULL, NULL);
|
||||
streams[2] =
|
||||
clCreateBuffer(context, CL_MEM_READ_WRITE, bufSize, NULL, NULL);
|
||||
if( streams[2] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating output array failed!\n");
|
||||
@@ -324,19 +327,24 @@ int test_twoToFloat_kernel_double(cl_command_queue queue, cl_context context, co
|
||||
fillWithTrickyNumbers_double( inDataA, inDataB, vecSize );
|
||||
|
||||
|
||||
streams[0] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_COPY_HOST_PTR), sizeof(cl_double) * vecSize * TEST_SIZE, inDataA, NULL);
|
||||
streams[0] =
|
||||
clCreateBuffer(context, CL_MEM_COPY_HOST_PTR,
|
||||
sizeof(cl_double) * vecSize * TEST_SIZE, inDataA, NULL);
|
||||
if( streams[0] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating input array A failed!\n");
|
||||
return -1;
|
||||
}
|
||||
streams[1] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_COPY_HOST_PTR), sizeof(cl_double) * vecSize * TEST_SIZE, inDataB, NULL);
|
||||
streams[1] =
|
||||
clCreateBuffer(context, CL_MEM_COPY_HOST_PTR,
|
||||
sizeof(cl_double) * vecSize * TEST_SIZE, inDataB, NULL);
|
||||
if( streams[1] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating input array B failed!\n");
|
||||
return -1;
|
||||
}
|
||||
streams[2] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_READ_WRITE), sizeof(cl_double) * TEST_SIZE, NULL, NULL);
|
||||
streams[2] = clCreateBuffer(context, CL_MEM_READ_WRITE,
|
||||
sizeof(cl_double) * TEST_SIZE, NULL, NULL);
|
||||
if( streams[2] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating output array failed!\n");
|
||||
@@ -555,13 +563,16 @@ int test_oneToFloat_kernel_double(cl_command_queue queue, cl_context context, co
|
||||
|
||||
fillWithTrickyNumbers_double( inDataA, NULL, vecSize );
|
||||
|
||||
streams[0] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_COPY_HOST_PTR), sizeof(cl_double) * vecSize * TEST_SIZE, inDataA, NULL);
|
||||
streams[0] =
|
||||
clCreateBuffer(context, CL_MEM_COPY_HOST_PTR,
|
||||
sizeof(cl_double) * vecSize * TEST_SIZE, inDataA, NULL);
|
||||
if( streams[0] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating input array A failed!\n");
|
||||
return -1;
|
||||
}
|
||||
streams[1] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_READ_WRITE), sizeof(cl_double) * TEST_SIZE, NULL, NULL);
|
||||
streams[1] = clCreateBuffer(context, CL_MEM_READ_WRITE,
|
||||
sizeof(cl_double) * TEST_SIZE, NULL, NULL);
|
||||
if( streams[1] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating output array failed!\n");
|
||||
@@ -759,13 +770,17 @@ int test_oneToOne_kernel_double(cl_command_queue queue, cl_context context, cons
|
||||
inDataA[ i ] = any_double(d);
|
||||
|
||||
|
||||
streams[0] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_COPY_HOST_PTR), sizeof(cl_double) * vecSize * TEST_SIZE, inDataA, NULL);
|
||||
streams[0] =
|
||||
clCreateBuffer(context, CL_MEM_COPY_HOST_PTR,
|
||||
sizeof(cl_double) * vecSize * TEST_SIZE, inDataA, NULL);
|
||||
if( streams[0] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating input array A failed!\n");
|
||||
return -1;
|
||||
}
|
||||
streams[1] = clCreateBuffer(context, (cl_mem_flags)(CL_MEM_READ_WRITE), sizeof(cl_double) * vecSize * TEST_SIZE, NULL, NULL);
|
||||
streams[1] =
|
||||
clCreateBuffer(context, CL_MEM_READ_WRITE,
|
||||
sizeof(cl_double) * vecSize * TEST_SIZE, NULL, NULL);
|
||||
if( streams[1] == NULL )
|
||||
{
|
||||
log_error("ERROR: Creating output array failed!\n");
|
||||
|
||||
Reference in New Issue
Block a user