diff options
author | Martin Kroeker <martin@ruby.chemie.uni-freiburg.de> | 2017-03-13 00:36:01 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-13 00:36:01 +0100 |
commit | ea26b00c067b5a8beef6f98b18551876e7985a16 (patch) | |
tree | 9b0418b510ae498d3d2b6cb429935e3f5146481c /common.h | |
parent | 9254a701f32ea9025204b686504df6367329fd72 (diff) | |
download | openblas-ea26b00c067b5a8beef6f98b18551876e7985a16.tar.gz openblas-ea26b00c067b5a8beef6f98b18551876e7985a16.tar.bz2 openblas-ea26b00c067b5a8beef6f98b18551876e7985a16.zip |
Fix CREAL,CIMAG macros for PGI
Diffstat (limited to 'common.h')
-rw-r--r-- | common.h | 9 |
1 files changed, 7 insertions, 2 deletions
@@ -556,8 +556,13 @@ static void __inline blas_lock(volatile BLASULONG *address){ #endif #if defined(C_PGI) || defined(C_SUN) -#define CREAL(X) (*((FLOAT *)&X + 0)) -#define CIMAG(X) (*((FLOAT *)&X + 1)) + #if defined(__STDC_IEC_559_COMPLEX__) + #define CREAL(X) creal(X) + #define CIMAG(X) cimag(X) + #else + #define CREAL(X) (*((FLOAT *)&X + 0)) + #define CIMAG(X) (*((FLOAT *)&X + 1)) + #endif #else #ifdef OPENBLAS_COMPLEX_STRUCT #define CREAL(Z) ((Z).real) |