mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
Fix Build Warnings for AArch64 (#2242)
This commit links to issue (#2234). When cross-compiling for AArch64, using gcc 13.3, you encounter three warnings types that turn into errors: - maybe-uninitialized - stringop-truncation - strict-aliasing This commit fixes all the warnings found, in regards to the first two rules. To resolve the warnigns due to strict-aliasing, I am editing the CMake build system. Signed-off-by: Antonios Christidis <a-christidis@ti.com>
This commit is contained in:
committed by
GitHub
parent
bcfa1f7c26
commit
2031e21a58
@@ -181,6 +181,10 @@ int test_get_image_info_single( cl_context context, image_descriptor *imageInfo,
|
||||
case CL_MEM_OBJECT_IMAGE3D:
|
||||
required_height = imageInfo->height;
|
||||
break;
|
||||
default:
|
||||
log_error("ERROR: Invalid imageInfo->type = %d\n", imageInfo->type);
|
||||
required_height = 0;
|
||||
break;
|
||||
}
|
||||
|
||||
size_t outHeight;
|
||||
@@ -204,6 +208,10 @@ int test_get_image_info_single( cl_context context, image_descriptor *imageInfo,
|
||||
case CL_MEM_OBJECT_IMAGE3D:
|
||||
required_depth = imageInfo->depth;
|
||||
break;
|
||||
default:
|
||||
log_error("ERROR: Invalid imageInfo->type = %d\n", imageInfo->type);
|
||||
required_depth = 0;
|
||||
break;
|
||||
}
|
||||
|
||||
size_t outDepth;
|
||||
@@ -227,6 +235,10 @@ int test_get_image_info_single( cl_context context, image_descriptor *imageInfo,
|
||||
case CL_MEM_OBJECT_IMAGE2D_ARRAY:
|
||||
required_array_size = imageInfo->arraySize;
|
||||
break;
|
||||
default:
|
||||
log_error("ERROR: Invalid imageInfo->type = %d\n", imageInfo->type);
|
||||
required_array_size = 0;
|
||||
break;
|
||||
}
|
||||
|
||||
size_t outArraySize;
|
||||
|
||||
Reference in New Issue
Block a user