Re: [eigen] compilation failure in CUDA/Half.h in non-nvcc build

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


Sorry about that. I disabled the use of the _cvtss_sh and _cvtsh_ss instructions when compiling with clang in the latest revision of the Eigen code base.

On Tue, Apr 19, 2016 at 9:02 PM, Chris Dyer <cdyer@xxxxxxxxxx> wrote:
Hi all,

Building with the new(?) LLVM-based g++ on Mac, I'm getting the following
/Users/cdyer/eigen-dev/Eigen/src/Core/arch/CUDA/Half.h:285:9: error: use of undeclared identifier '_cvtss_sh'
  h.x = _cvtss_sh(ff, 0);
        ^
/Users/cdyer/eigen-dev/Eigen/src/Core/arch/CUDA/Half.h:338:10: error: use of undeclared identifier '_cvtsh_ss'
  return _cvtsh_ss(h.x);

Poking around, it looks like there was a recent change to LLVM to add these intrinsics this change hasn't made it into the standard Xcode release (which most mac developers use, I think).

Adding
   #undef EIGEN_HAS_FP16_C
will fix this, but I'm not quite sure what the appropriate ifdef guard is. Fixing this could be quite useful for your Mac users.

Best,
Chris
(Apologies for not submitting to Bugzilla, even after reseting my password I'm unable to log in properly).



--
Benoit


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/