21 #ifndef EIGEN_TYPE_CASTING_SYCL_H 22 #define EIGEN_TYPE_CASTING_SYCL_H 27 #ifdef SYCL_DEVICE_ONLY 29 struct type_casting_traits<
float,
int> {
35 pcast<cl::sycl::cl_float4, cl::sycl::cl_int4>(
const cl::sycl::cl_float4&
a) {
37 .template convert<cl::sycl::cl_int, cl::sycl::rounding_mode::automatic>();
41 struct type_casting_traits<
int,
float> {
47 pcast<cl::sycl::cl_int4, cl::sycl::cl_float4>(
const cl::sycl::cl_int4&
a) {
48 return a.template
convert<cl::sycl::cl_float,
49 cl::sycl::rounding_mode::automatic>();
53 struct type_casting_traits<double,
float> {
59 pcast<cl::sycl::cl_double2, cl::sycl::cl_float4>(
60 const cl::sycl::cl_double2&
a,
const cl::sycl::cl_double2&
b) {
61 auto a1 = a.template
convert<cl::sycl::cl_float,
62 cl::sycl::rounding_mode::automatic>();
63 auto b1 =
b.template
convert<cl::sycl::cl_float,
64 cl::sycl::rounding_mode::automatic>();
65 return cl::sycl::float4(
a1.x(),
a1.y(), b1.x(), b1.y());
69 struct type_casting_traits<
float, double> {
75 pcast<cl::sycl::cl_float4, cl::sycl::cl_double2>(
const cl::sycl::cl_float4&
a) {
77 return cl::sycl::cl_double2(a.x(), a.y());
85 #endif // EIGEN_TYPE_CASTING_SYCL_H
#define EIGEN_ALWAYS_INLINE
Namespace containing all symbols from the Eigen library.
#define EIGEN_DEVICE_FUNC
static BinaryMeasurement< Rot3 > convert(const BetweenFactor< Pose3 >::shared_ptr &f)