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 __malloc__ errors on Fedora 35 and Ubuntu Impish #3293

Closed
totaam opened this issue Oct 1, 2021 · 5 comments
Closed

CUDA __malloc__ errors on Fedora 35 and Ubuntu Impish #3293

totaam opened this issue Oct 1, 2021 · 5 comments

Comments

@totaam
Copy link
Collaborator

totaam commented Oct 1, 2021

CUDA compiling BGRA_to_YUV444   (no file)
 '/opt/cuda-11.4/bin/nvcc' '-fatbin' '-c' 'fs/share/xpra/cuda/BGRA_to_YUV444.cu' '-o' 'fs/share/xpra/cuda/BGRA_to_YUV444.fatbin' '-std=c++03' '-gencode=arch=compute_52,code=sm_52' '-gencode=arch=compute_53,code=sm_53' '-gencode=arch=compute_60,code=sm_60' '-gencode=arch=compute_61,code=sm_61' '-gencode=arch=compute_62,code=sm_62' '-gencode=arch=compute_70,code=sm_70' '-gencode=arch=compute_75,code=sm_75' '-gencode=arch=compute_80,code=sm_80' '-gencode=arch=compute_86,code=sm_86'
Error: failed to compile CUDA kernel BGRA_to_YUV444
 using command: ['/opt/cuda-11.4/bin/nvcc', '-fatbin', '-c', 'fs/share/xpra/cuda/ARGB_to_NV12.cu', '-o', 'fs/share/xpra/cuda/ARGB_to_NV12.fatbin', '-std=c++03', '-gencode=arch=compute_52,code=sm_52', '-gencode=arch=compute_53,code=sm_53', '-gencode=arch=compute_60,code=sm_60', '-gencode=arch=compute_61,code=sm_61', '-gencode=arch=compute_62,code=sm_62', '-gencode=arch=compute_70,code=sm_70', '-gencode=arch=compute_75,code=sm_75', '-gencode=arch=compute_80,code=sm_80', '-gencode=arch=compute_86,code=sm_86']
/usr/include/stdio.h(183): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(195): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(217): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(254): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(279): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(288): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(297): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(303): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(309): error: attribute "__malloc__" does not take arguments
/usr/include/stdio.h(824): error: attribute "__malloc__" does not take arguments
/usr/include/stdlib.h(565): error: attribute "__malloc__" does not take arguments
/usr/include/stdlib.h(569): error: attribute "__malloc__" does not take arguments
/usr/include/stdlib.h(797): error: attribute "__malloc__" does not take arguments
13 errors detected in the compilation of "fs/share/xpra/cuda/ARGB_to_NV12.cu".

So CUDA can't deal with the new glibc headers.

@totaam
Copy link
Collaborator Author

totaam commented Oct 4, 2021

We skip nvenc on Fedora 35: 059638b.

@totaam
Copy link
Collaborator Author

totaam commented Oct 16, 2021

I fumbled the fix for Impish: 99eea8f (Hirsute is fine!), wrong lsb-release command (c115f15), tried to simplify it (fadfa6d), this syntax looked like it would work: 5d552d2, but cut&pasted wrong (8d705dc) then finally realized that the containers were just missing a dependency: d447c73

@totaam
Copy link
Collaborator Author

totaam commented Oct 21, 2021

nvidia just released CUDA 11.5 and the problem is still there:

Error: failed to compile CUDA kernel BGRA_to_YUV444
 using command: ['/opt/cuda-11.5/bin/nvcc', '-fatbin', '-c', 'fs/share/xpra/cuda/ARGB_to_YUV444.cu', '-o', 'fs/share/xpra/cuda/ARGB_to_YUV444.fatbin', '-std=c++03', '-gencode=arch=compute_52,code=sm_52', '-gencode=arch=compute_53,code=sm_53', '-gencode=arch=compute_60,code=sm_60', '-gencode=arch=compute_61,code=sm_61', '-gencode=arch=compute_62,code=sm_62', '-gencode=arch=compute_70,code=sm_70', '-gencode=arch=compute_75,code=sm_75', '-gencode=arch=compute_80,code=sm_80', '-gencode=arch=compute_86,code=sm_86']

/usr/include/stdio.h(183): error: attribute "__malloc__" does not take arguments
(...)

@totaam
Copy link
Collaborator Author

totaam commented Nov 30, 2021

The fix is included in CUDA 11.5.1 and so the commit above re-enables CUDA (nvenc, nvfbc and nvjpeg support) for Fedora 35 and Ubuntu Impish.

@totaam totaam closed this as completed Nov 30, 2021
totaam added a commit that referenced this issue Dec 3, 2021
totaam added a commit that referenced this issue Dec 3, 2021
@totaam
Copy link
Collaborator Author

totaam commented Mar 30, 2022

CUDA 11.5.2 works with Fedora 36's GCC 12, see #3458

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant