From d28ee082b0844086ee9b9cfb50825427f0b3a48a Mon Sep 17 00:00:00 2001 From: Cedric Nugteren Date: Fri, 7 Apr 2017 07:35:15 +0200 Subject: Uses float2 and double2 for base complex data-types instead of a custom struct; fixes bug on Apple OpenCL --- src/kernels/common.opencl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/kernels/common.opencl') diff --git a/src/kernels/common.opencl b/src/kernels/common.opencl index 32e3fbb9..db4c8ec4 100644 --- a/src/kernels/common.opencl +++ b/src/kernels/common.opencl @@ -69,7 +69,7 @@ R"( // Complex single-precision #elif PRECISION == 3232 - typedef struct cfloat {float x; float y;} real; + typedef float2 real; typedef struct cfloat2 {real x; real y;} real2; typedef struct cfloat4 {real x; real y; real z; real w;} real4; typedef struct cfloat8 {real s0; real s1; real s2; real s3; @@ -84,7 +84,7 @@ R"( // Complex double-precision #elif PRECISION == 6464 - typedef struct cdouble {double x; double y;} real; + typedef double2 real; typedef struct cdouble2 {real x; real y;} real2; typedef struct cdouble4 {real x; real y; real z; real w;} real4; typedef struct cdouble8 {real s0; real s1; real s2; real s3; -- cgit v1.2.3