pocl: Can't build on NVIDIA Jetson (aarch64 / Ubuntu Bionic / CUDA)
I’ve got an NVIDIA Jetson AGX Xavier development kit and I’m trying to compile POCL 1.6 RC1 on it. The hardware is an 8-core aarch64
CPU with an NVIDIA CUDA-compatible GPU. The OS is Ubuntu Bionic for arm64
with most of the NVIDIA tools, including CUDA 10.2.
The most recent LLVM / CLANG available is 10, so that’s what I’ve installed. The cmake
step is throwing an error:
-- The C compiler identification is GNU 7.5.0
-- The CXX compiler identification is GNU 7.5.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Performing Test HAVE_WARN_INCOMPATIBLE_POINTER_TYPES
-- Performing Test HAVE_WARN_INCOMPATIBLE_POINTER_TYPES - Success
-- Setting build type to 'RelWithDebInfo' as none was specified.
-- No git and/or not a prerelease -> not adding git commit to version.
-- Host CPU cores: 8
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.1")
-- Checking for module 'hwloc'
-- Found hwloc, version 1.11.9
-- Found Hwloc: hwloc
-- Found hwloc 1.11.9 in :hwloc
-- Hwloc_VERSION 1.11.9
-- Hwloc_LDFLAGS -lhwloc
-- Hwloc_CFLAGS
-- L1D Cacheline size detected: 64
-- Using llvm-config: /usr/bin/llvm-config-10
-- LLVM binaries suffix : -10
-- llvm-config's LLVM_PREFIX is: /usr/lib/llvm-10
-- llvm-config's LLVM_VERSION_FULL is: 10.0.0
-- LLVM_VERSION: 10.0
-- llvm-config's LLVM_CFLAGS is: -I/usr/lib/llvm-10/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
-- llvm-config's LLVM_CXXFLAGS is: -I/usr/lib/llvm-10/include -std=c++14 -fno-exceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
-- llvm-config's LLVM_CPPFLAGS is: -I/usr/lib/llvm-10/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
-- llvm-config's LLVM_LDFLAGS is: -L/usr/lib/llvm-10/lib
-- llvm-config's LLVM_BINDIR is: /usr/lib/llvm-10/bin
-- llvm-config's LLVM_LIBDIR is: /usr/lib/llvm-10/lib
-- llvm-config's LLVM_INCLUDEDIR is: /usr/lib/llvm-10/include
-- llvm-config's LLVM_SRC_ROOT is: /usr/lib/llvm-10/build/
-- llvm-config's LLVM_OBJ_ROOT is: /usr/lib/llvm-10/build/
-- llvm-config's LLVM_ALL_TARGETS is: AArch64 AMDGPU ARM BPF Hexagon Lanai Mips MSP430 NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore AVR
-- llvm-config's LLVM_HOST_TARGET is: aarch64-unknown-linux-gnu
-- llvm-config's LLVM_BUILD_MODE is: RelWithDebInfo
-- llvm-config's LLVM_ASSERTS_BUILD is: OFF
-- llvm-config's LLVM_SYSLIBS is:
-- llvm-config's LLVM_HAS_RTTI is: YES
-- llvm-config's LLVM_LIBS is: -lLLVM-10
-- llvm-config's LLVM_SYSLIBS is:
-- Found clang: /usr/lib/llvm-10/bin/clang-10
-- Found clang++: /usr/bin/clang++-10
-- Found opt: /usr/bin/opt-10
-- Found llc: /usr/bin/llc-10
-- Found llvm-as: /usr/bin/llvm-as-10
-- Found llvm-link: /usr/bin/llvm-link-10
-- Found lli: /usr/bin/lli-10
-- udivmodti4 compiles without extra flags
-- Checking if clang++ works (required by vecmathlib)
-- Checking if LLVM is a DEBUG build
-- DEBUG build
-- Find out LLC target triple (for host aarch64-unknown-linux-gnu)
-- Find out LLC host CPU with /usr/bin/llc-10
-- Autodetected CPU (unknown) overriden by user to aarch64
-- Checking clang -march vs. -mcpu flag
CMake Error at cmake/LLVM.cmake:731 (message):
Could not determine whether to use -march or -mcpu with clang
Call Stack (most recent call first):
CMakeLists.txt:459 (include)
-- Configuring incomplete, errors occurred!
See also "/usr/local/src/pocl-1.6-RC1/build/CMakeFiles/CMakeOutput.log".
The command '/bin/sh -c $SCRIPTS/pocl-cuda.sh #> $LOGS/pocl-cuda.log 2>&1' returned a non-zero code: 1
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 33 (13 by maintainers)
You can close this as fixed in 1.6.
Final score - 71 tests, all passed!
By the way, if you want my Docker context, let me know. It’s a bit different from the way your Docker contexts work because it has to integrate into my end-user image, but it’s fully functional on its own.