From 2b23805e1d08705b35b1a6f79c31b10f4f735c40 Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Fri, 10 Feb 2012 09:10:57 +1100 Subject: [PATCH] Fix kernel selection process and build error. --- ocl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ocl.c b/ocl.c index e0aafb11..a456b0c4 100644 --- a/ocl.c +++ b/ocl.c @@ -313,7 +313,7 @@ _clState *initCl(unsigned int gpu, char *name, size_t nameSize) return NULL; } find = strstr(devoclver, ocl10); - if !(find) + if (!find) clState->hasOpenCL11plus = true; status = clGetDeviceInfo(devices[gpu], CL_DEVICE_PREFERRED_VECTOR_WIDTH_INT, sizeof(cl_uint), (void *)&clState->preferred_vwidth, NULL); @@ -361,7 +361,7 @@ _clState *initCl(unsigned int gpu, char *name, size_t nameSize) char filename[16]; if (chosen_kernel == KL_NONE) { - if (strstr(name, "Tahiti")) + if (!strstr(name, "Tahiti")) chosen_kernel = KL_DIAKGCN; else if (!clState->hasBitAlign) chosen_kernel = KL_POCLBM;