-
Notifications
You must be signed in to change notification settings - Fork 111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Grid does not compile on Arm with CUDA #450
Comments
To add: This also occurs on Grace Hopper. |
Use CXXFLAGS - there are other neon compilers that are happy with Eigen. |
e.g. clang++ should work fine as a host compiler, Ive used it fine on Ampere |
Also -- feel free to contribute a config-command and directory under Systems/GraceHopper or similar. |
I must be missing something—I've used |
I'm puzzled by that, because I thought that nvcc does two things: |
|
You could almost certainly remove Grid from this problem as the challenge appears to be to get Eigen to work with nvcc and your host compile with -DEIGEN_DONT_VECTORIZE set. This is a reasonable expectation of Eigen and nvcc / host compiler. I'd bet a -Xcompiler -march=armv8-a is needed. See configure.ac for an example:
|
Yes, the example code upthread compiles without issue in
Ah, if the expectation is that we need to use And indeed, this is not necessarily Grid specific, it's general to trying to compile Eigen for an Arm host with |
Describe the issue:
Attempting to compile Grid for NVIDIA on Arm fails due to a large number of undefined symbols in
arm_neon.h
. Following up on @agsunderland's comment on #430 and digging deeper, after some discussion with @RChrHill the issue is that including Eigen with__CUDACC__
undef
ined causes Eigen to emit code using NEON vector instructions, which according to this post on NVIDIA's forums aren't yet supported in NVCC.A workaround is to define the
EIGEN_DONT_VECTORIZE
macro, for example by adding-DEIGEN_DONT_VECTORIZE
to theCXXFLAGS
; this disables Eigen from using SIMD completely. I'm not sure what performance impact this has compared to being able to use NEON for the things that Eigen is used for on CPU. Upgrading to Eigen 3.4.0 did not fix the problem.To compile the minimal example below, the following was used:
(Replace the
../../Grid
with the path to wherever Eigen is available.)Code example:
Target platform:
This is the Arm GPU testbed in Leicester; there is no model name in the
cpuinfo
.Configure options:
The text was updated successfully, but these errors were encountered: