aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Core/arch/GPU
diff options
context:
space:
mode:
authorGravatar Mehdi Goli <mehdi.goli@codeplay.com>2018-08-03 16:59:15 +0100
committerGravatar Mehdi Goli <mehdi.goli@codeplay.com>2018-08-03 16:59:15 +0100
commit01358300d581f94c842bcdf35266b50f2795ded3 (patch)
tree7fa0714ebafc01c946bc18e3bf09a794d01f91db /Eigen/src/Core/arch/GPU
parent62169419aba9048c6c66c71ce4910241e594cbe1 (diff)
Creating separate SYCL required PR for uncontroversial files.
Diffstat (limited to 'Eigen/src/Core/arch/GPU')
-rw-r--r--Eigen/src/Core/arch/GPU/Half.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/Eigen/src/Core/arch/GPU/Half.h b/Eigen/src/Core/arch/GPU/Half.h
index ab9d27591..aca56fa72 100644
--- a/Eigen/src/Core/arch/GPU/Half.h
+++ b/Eigen/src/Core/arch/GPU/Half.h
@@ -83,7 +83,11 @@ struct __half_raw {
#if defined(EIGEN_CUDACC_VER) && EIGEN_CUDACC_VER < 90000
// In CUDA < 9.0, __half is the equivalent of CUDA 9's __half_raw
typedef __half __half_raw;
- #endif
+ #endif // defined(EIGEN_HAS_CUDA_FP16)
+
+#elif defined(EIGEN_USE_SYCL) && defined(__SYCL_DEVICE_ONLY__)
+typedef cl::sycl::half __half_raw;
+
#endif
EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC __half_raw raw_uint16_to_half(unsigned short x);
@@ -200,6 +204,7 @@ struct half : public half_impl::half_base {
x = other.x;
return *this;
}
+
};
} // end namespace Eigen