I am trying to use math builtin functions (exp, cos) with double precision on OSX (macbook pro, nvidia GT 330M). My sample code looks like

#pragma OPENCL EXTENSION cl_khr_fp64 : enable
__kernel void g(
__global double* input,
__global double* output,
const unsigned int count)
int i = get_global_id(0);
if(i < count) {
output[i] = exp(.1*input[i]);

i get a failure when trying to build the opencl executable with a message like:

error: more than one matching function found in __builtin_overload
output[i] = exp((.1*input[i]));

i have tried exp, native_exp, and have also tried various typecastings as was suggested on some other posts. it seems like i am not giving the compiler enough info to pick out the double precision routine? i am able to make this all work using float, but need to move to double.

any ideas? thanks.