mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-21 14:59:02 +00:00
* Fixes issue #497 - Image tests from master branch on OCL 1.2 device * Fixes issue #497 - use get_device_cl_version
This commit is contained in:
committed by
Kévin Petit
parent
841123040e
commit
daafdac555
@@ -1,6 +1,6 @@
|
||||
//
|
||||
// Copyright (c) 2017 The Khronos Group Inc.
|
||||
//
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
@@ -18,7 +18,7 @@
|
||||
#define MAX_ERR 0.005f
|
||||
#define MAX_HALF_LINEAR_ERR 0.3f
|
||||
|
||||
extern bool gDebugTrace, gTestSmallImages, gTestMaxImages;
|
||||
extern bool gDebugTrace, gTestSmallImages, gTestMaxImages, gDeviceLt20;
|
||||
|
||||
typedef struct image_kernel_data
|
||||
{
|
||||
@@ -65,7 +65,6 @@ static int test_get_1Dimage_info_single( cl_context context, cl_command_queue qu
|
||||
// Construct testing source
|
||||
if( gDebugTrace )
|
||||
log_info( " - Creating 1D image %d ...\n", (int)imageInfo->width );
|
||||
|
||||
image = create_image_1d( context, (cl_mem_flags)(CL_MEM_READ_ONLY), imageInfo->format, imageInfo->width, 0, NULL, NULL, &error );
|
||||
if( image == NULL )
|
||||
{
|
||||
@@ -94,7 +93,7 @@ static int test_get_1Dimage_info_single( cl_context context, cl_command_queue qu
|
||||
if (error)
|
||||
print_error(error, "clFinish failed.\n");
|
||||
const char *ptr = programSrc;
|
||||
error = create_single_kernel_helper_with_build_options( context, &program, &kernel, 1, &ptr, "sample_kernel", "-cl-std=CL2.0" );
|
||||
error = create_single_kernel_helper_with_build_options( context, &program, &kernel, 1, &ptr, "sample_kernel", gDeviceLt20 ? "" : "-cl-std=CL2.0" );
|
||||
test_error( error, "Unable to create kernel to test against" );
|
||||
|
||||
// Create an output buffer
|
||||
|
||||
Reference in New Issue
Block a user