nvcc compilation problem

Hi folks,

I can’t for the life of me build some binaries for Jetson.
Here are my settings:

  • on the host machine I have Ubuntu 14.04 and I use Nsight Eclipse Edition with the CUDA Toolkit 6.5 toolchain
  • my target system CPU Architecture is set to ARM
  • I build with the following compiler settings: nvcc -std=c++11 -mfloat-abi=softfp -mfpu=neon

No matter what I try, when I include arm_neon.h I always get the error “You must enable NEON instructions (e.g. -mfloat-abi=softfp -mfpu=neon) to use arm_neon.h”

Any ideas?

Not sure how this will change errors, but Jetson uses hard-float calling convention (armeabihf). “softfp” might be the issue.

Tried -mfloat-abi=hard and -mfloat-abi=armeabihf , same errors…

Probably, you get more information of the compilation error by added “-v” option(nvcc verbose output).
Is it possible to provide a sample code here to exhibit this problem?

Have you tried passing them to nvcc after the “-Xcompiler” flag?

e.g.

-Xcompiler -mfloat-abi=hard -mfpu=neon [... rest of your CFLAGS ... ]

http://docs.nvidia.com/cuda/cuda-compiler-driver-nvcc/#options-for-passing-specific-phase-options