Skip to content
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

CUDA compilation GCC 5.4.0 #1792

Closed
schweitzer opened this issue Jan 9, 2017 · 4 comments
Closed

CUDA compilation GCC 5.4.0 #1792

schweitzer opened this issue Jan 9, 2017 · 4 comments

Comments

@schweitzer
Copy link
Contributor

Hi,
PCL fails to compile from sources on release with gcc 5.4 and cuda 7.5.

Your Environment

  • Operating System and version: Linux Mint 18.1
  • Compiler: GCC 5.4
  • PCL Version: Latest release pcl-1.8.0

Current Behavior

The compilation fails with this kind of errors:

/usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ CMake Error at cuda_compile_generated_bilateral_pyrdown.cu.o.Release.cmake:267 (message): Error generating file /home/mschweitzer/dev/f4s/deps/build/release/pcl/pcl-prefix/src/pcl-build/gpu/kinfu/CMakeFiles/cuda_compile.dir/src/cuda/./cuda_compile_generated_bilateral_pyrdown.cu.o

It seems that this kind of cuda error is common (like here in TensorFlow or also here )

Possible Solution

A possible walktrough is to add -D_FORCE_INLINES to PCL CUDA_NVCC_FLAGS (this works for me).

Maybe an update to the Cuda 8.0 version can also resolve this issue but I didn't try it.

Am I the only one getting this error ?

Thanks,

@taketwo
Copy link
Member

taketwo commented Jan 9, 2017

From my experience this flag is also needed with CUDA 8.0. I had to use it in several of my projects, but I was never concerned with backward compatibility. If we don't break building with older GCC/CUDA by adding this flag, then we should add it I think.

@soulslicer
Copy link

soulslicer commented Jan 18, 2017

I have never gotten any of the cuda libraries to work with the new pascal series of gpus. have you?

@taketwo
Copy link
Member

taketwo commented Jan 19, 2017

I don't have a Pascal GPU, unfortunately.

@soulslicer
Copy link

Turns out CUDA 8.0 solves this. My bad

@taketwo taketwo closed this as completed Jan 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants