summaryrefslogtreecommitdiff
path: root/src/kernels/common.opencl
diff options
context:
space:
mode:
authorCedric Nugteren <web@cedricnugteren.nl>2017-04-07 07:35:15 +0200
committerCedric Nugteren <web@cedricnugteren.nl>2017-04-07 07:35:15 +0200
commitd28ee082b0844086ee9b9cfb50825427f0b3a48a (patch)
treeefc66574f3508c1c848f480b4dfa15afa6d00bb5 /src/kernels/common.opencl
parentce369702d88a679d906677d9266a17cb72d78ff7 (diff)
Uses float2 and double2 for base complex data-types instead of a custom struct; fixes bug on Apple OpenCL
Diffstat (limited to 'src/kernels/common.opencl')
-rw-r--r--src/kernels/common.opencl4
1 files changed, 2 insertions, 2 deletions
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;