0

I installed CUDA 3.0 version to compile something. I am doing it on some server where I don't have permission to install extra stuff (I installed it in my home directory). This is the compilation command:

/home/susers/s218176/cuda3/cuda/bin/nvcc -O3 -use_fast_math -DUSING_CUDA -DKERNEL_BAL -D_NOT_USING_MPI -I/home/susers/s218176/cuda3/cuda/include/ -I/home/susers/s218176/cuda3/cuda/samples/common/inc/ -I/home/susers/s218176/cuda3/C/common/inc/ -L/home/susers/s218176/cuda3/C/lib/ -L/home/susers/s218176/cuda3/cuda/lib64/  -lcutil_x86_64 -lcudart -lm --ptxas-options=-v -gencode=arch=compute_13,code=sm_13 -gencode=arch=compute_13,code=compute_13 -gencode=arch=compute_20,code=sm_20 -gencode=arch=compute_20,code=compute_20 mcgpu.cu -o mpgpu.x

And I got some errors:

/usr/include/x86_64-linux-gnu/bits/byteswap.h(47): error: identifier "__builtin_bswap32" is undefined

/usr/include/x86_64-linux-gnu/bits/byteswap.h(111): error: identifier "__builtin_bswap64" is undefined

/usr/include/c++/4.8/cstdlib(178): error: identifier "__int128" is undefined

/usr/include/c++/4.8/cstdlib(179): error: identifier "__int128" is undefined

kernel.cu(175): error: identifier "clock64" is undefined

kernel.cu(187): error: identifier "__ballot" is undefined

6 errors detected in the compilation of "/tmp/tmpxft_00007068_00000000-6_mcgpu.compute_13.cpp1.ii".

I read that its because my gcc version is incompatible with this version of CUDA. Is there possibility to do a downgrade (or something like install in home directory and to tell nvcc to use this ver.) without full permissions? Please help.

Edit: Already installed g++:

/usr/bin/g++ /usr/bin/g++-4.8

Kernel version:

Linux supermicro 3.16.0-30-generic #40~14.04.1-Ubuntu SMP Thu Jan 15 17:43:14 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

Community
  • 1
  • 1
demoo
  • 111
  • 2
  • 3
  • 11
  • Please edit your post to include the name and version of your 'Linux OS'. ... Getting a list of the already installed compilers : `$ ls /usr/bin/g++*` – Knud Larsen May 21 '16 at 09:04
  • Ok, done. Someone mark this like duplicate question but there user have full permissions, I don't. – demoo May 21 '16 at 09:36
  • @demoo: You don't need full permissions. Install or compile a compatible gcc version locally and use the nvcc option in the duplicate. If you don't know how to build or install a local gcc version, that is a completely non-CUDA related question you should probably ask separately, and maybe not on [SO] – talonmies May 21 '16 at 09:37
  • I did everything that was in post of kennethfm from topic u link @talonmies, I downloaded gcc4.4 from http://packages.ubuntu.com/en/precise/gcc-4.4 and now when I'm trying to compile with my nvcc I'm getting this error: "gcc: error trying to exec 'cc1plus': execvp: No such file or directory". It's mean that now I need to install g++? – demoo May 22 '16 at 12:26
  • Please open a new thread in http://askubuntu.com/questions . This Forum, http://stackoverflow.com/questions is for programming questions only. The Ubuntu gcc-4.4 / g++-4.4 are not portable, will look for non existing "4.4 files" in /usr/ . What you need is a dedicated gcc-4.4.7, compiled for /home/susers/. ( I can do that, and upload a package.) – Knud Larsen May 23 '16 at 10:39

0 Answers0