mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
gles: Fix compile warnings. (#1070)
* gles: Fix compile warnings. For 32 and 64-bit Visual Studio and the Android Q NDK. * Fix formatting violations Co-authored-by: spauls <spauls@qti.qualcomm.com>
This commit is contained in:
committed by
GitHub
parent
17a0d09567
commit
6c8045911a
@@ -18,3 +18,11 @@ set (${MODULE_NAME}_SOURCES
|
||||
list(APPEND CLConform_LIBRARIES EGL GLESv2)
|
||||
|
||||
include(../CMakeCommon.txt)
|
||||
|
||||
if(DEFINED USE_GLES3)
|
||||
target_compile_definitions(${${MODULE_NAME}_OUT} PRIVATE GLES3)
|
||||
endif()
|
||||
if(MSVC)
|
||||
# Don't warn about using the portable "strdup" function.
|
||||
target_compile_definitions(${${MODULE_NAME}_OUT} PRIVATE _CRT_NONSTDC_NO_DEPRECATE)
|
||||
endif()
|
||||
@@ -117,7 +117,8 @@ public:
|
||||
_platform, "clGetGLContextInfoKHR");
|
||||
if (GetGLContextInfo == NULL)
|
||||
{
|
||||
print_error(status, "clGetGLContextInfoKHR failed");
|
||||
log_error("ERROR: clGetGLContextInfoKHR failed! (%s:%d)\n",
|
||||
__FILE__, __LINE__);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -128,7 +129,7 @@ public:
|
||||
return NULL;
|
||||
}
|
||||
dev_size /= sizeof(cl_device_id);
|
||||
log_info("GL _context supports %d compute devices\n", dev_size);
|
||||
log_info("GL _context supports %zu compute devices\n", dev_size);
|
||||
|
||||
status =
|
||||
GetGLContextInfo(properties, CL_CURRENT_DEVICE_FOR_GL_CONTEXT_KHR,
|
||||
|
||||
@@ -570,10 +570,12 @@ int test_fence_sync_single( cl_device_id device, cl_context context, cl_command_
|
||||
{
|
||||
if( p[ t ] == 0 )
|
||||
{
|
||||
log_error( "RUN: %ld to %ld (%d,%d to %d,%d) 0x%08x\n", a, t - 1,
|
||||
(int)( a % framebufferSize ), (int)( a / framebufferSize ),
|
||||
(int)( ( t - 1 ) % framebufferSize ), (int)( ( t - 1 ) / framebufferSize ),
|
||||
p[ a ] );
|
||||
log_error(
|
||||
"RUN: %zu to %zu (%d,%d to %d,%d) 0x%08x\n",
|
||||
a, t - 1, (int)(a % framebufferSize),
|
||||
(int)(a / framebufferSize),
|
||||
(int)((t - 1) % framebufferSize),
|
||||
(int)((t - 1) / framebufferSize), p[a]);
|
||||
a = t;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -369,7 +369,9 @@ int test_images_read_cube( cl_device_id device, cl_context context, cl_command_q
|
||||
}
|
||||
|
||||
|
||||
#ifdef __APPLE__
|
||||
#pragma mark -------------------- Write tests -------------------------
|
||||
#endif
|
||||
|
||||
|
||||
int test_cl_image_write( cl_context context, cl_command_queue queue, cl_mem clImage,
|
||||
|
||||
@@ -197,7 +197,9 @@ int test_renderbuffer_read( cl_device_id device, cl_context context, cl_command_
|
||||
}
|
||||
|
||||
|
||||
#ifdef __APPLE__
|
||||
#pragma mark -------------------- Write tests -------------------------
|
||||
#endif
|
||||
|
||||
int test_attach_renderbuffer_write_to_image( cl_context context, cl_command_queue queue, GLenum glTarget, GLuint glRenderbuffer,
|
||||
size_t imageWidth, size_t imageHeight, cl_image_format *outFormat, ExplicitType *outType, MTdata d, void **outSourceBuffer )
|
||||
|
||||
Reference in New Issue
Block a user