CNTK icon indicating copy to clipboard operation
CNTK copied to clipboard

issue compiling MathCUDA with CUDA 8.0

Open clintjcampbell opened this issue 10 years ago • 7 comments

I can't get MathCUDA to compile correctly and get the following issues. Any pointers on what may need changing. I set up according to the tutorial and according to the Cuda 8 instructions to avoid the Curand error I was seeing from 7.5 on the pascal architecture.

------ Build started: Project: MathCUDA, Configuration: Release x64 ------ 1> Compiling CUDA source file GPUTensor.cu... 1> Compiling CUDA source file GPUSparseMatrix.cu... 1>
1>
1> C:\cntk\cntk\Source\Math>"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\bin\nvcc.exe" -gencode=arch=compute_30,code="sm_30,compute_30" -gencode=arch=compute_35,code="sm_35,compute_35" -gencode=arch=compute_50,code="sm_50,compute_50" --use-local-env --cl-version 2013 -Xcompiler /WX -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64" -IC:\cntk\cntk\Source\Common\include -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -I"c:\src\cub-1.5.4\" -I"C:\NVIDIA\cudnn-5.1\cuda\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" --source-in-ptx -lineinfo --keep --keep-dir C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA -maxrregcount=0 --machine 64 --compile -cudart static -Xcudafe "--diag_suppress=field_without_dll_interface" -Xcompiler "/wd 4819" -use_fast_math -DNO_SYNC -DWIN32 -D_WINDOWS -D_USRDLL -DMATH_EXPORTS -DUSE_CUDNN -D_UNICODE -DUNICODE -DNDEBUG -Xcompiler "/EHsc /W4 /nologo /O2 /FS /Zi /MD " -o C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA\GPUTensor.cu.obj "C:\cntk\cntk\Source\Math\GPUTensor.cu" 1> C:\cntk\cntk\Source\Math>"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\bin\nvcc.exe" -gencode=arch=compute_30,code="sm_30,compute_30" -gencode=arch=compute_35,code="sm_35,compute_35" -gencode=arch=compute_50,code="sm_50,compute_50" --use-local-env --cl-version 2013 -Xcompiler /WX -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64" -IC:\cntk\cntk\Source\Common\include -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -I"c:\src\cub-1.5.4\" -I"C:\NVIDIA\cudnn-5.1\cuda\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -lineinfo --keep-dir C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA -maxrregcount=0 --machine 64 --compile -cudart static -Xcudafe "--diag_suppress=field_without_dll_interface" -Xcompiler "/wd 4819" -use_fast_math -DNO_SYNC -DWIN32 -D_WINDOWS -D_USRDLL -DMATH_EXPORTS -DUSE_CUDNN -D_UNICODE -DUNICODE -DNDEBUG -Xcompiler "/EHsc /W4 /nologo /O2 /FS /Zi /MD " -o C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA\GPUSparseMatrix.cu.obj "C:\cntk\cntk\Source\Math\GPUSparseMatrix.cu" 1> GPUSparseMatrix.cu 1>c:\src\cub-1.5.4\cub\util_allocator.cuh(700): error C2220: warning treated as error - no 'object' file generated 1>c:\src\cub-1.5.4\cub\util_allocator.cuh(700): warning C4512: 'cub::CachingDeviceAllocator' : assignment operator could not be generated 1> c:\src\cub-1.5.4\cub\util_allocator.cuh(101) : see declaration of 'cub::CachingDeviceAllocator' 1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\BuildCustomizations\CUDA 8.0.targets(687,9): error MSB3721: The command ""C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\bin\nvcc.exe" -gencode=arch=compute_30,code="sm_30,compute_30" -gencode=arch=compute_35,code="sm_35,compute_35" -gencode=arch=compute_50,code="sm_50,compute_50" --use-local-env --cl-version 2013 -Xcompiler /WX -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64" -IC:\cntk\cntk\Source\Common\include -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -I"c:\src\cub-1.5.4\" -I"C:\NVIDIA\cudnn-5.1\cuda\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -lineinfo --keep-dir C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA -maxrregcount=0 --machine 64 --compile -cudart static -Xcudafe "--diag_suppress=field_without_dll_interface" -Xcompiler "/wd 4819" -use_fast_math -DNO_SYNC -DWIN32 -D_WINDOWS -D_USRDLL -DMATH_EXPORTS -DUSE_CUDNN -D_UNICODE -DUNICODE -DNDEBUG -Xcompiler "/EHsc /W4 /nologo /O2 /FS /Zi /MD " -o C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA\GPUSparseMatrix.cu.obj "C:\cntk\cntk\Source\Math\GPUSparseMatrix.cu"" exited with code 2. 1> Skipping CUDA source file MatrixQuantizer_kernel.cu (excluded from build). 1> Compiling CUDA source file GPUMatrix.cu... 1>
1> C:\cntk\cntk\Source\Math>"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\bin\nvcc.exe" -gencode=arch=compute_30,code="sm_30,compute_30" -gencode=arch=compute_35,code="sm_35,compute_35" -gencode=arch=compute_50,code="sm_50,compute_50" --use-local-env --cl-version 2013 -Xcompiler /WX -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64" -IC:\cntk\cntk\Source\Common\include -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -I"c:\src\cub-1.5.4\" -I"C:\NVIDIA\cudnn-5.1\cuda\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -lineinfo --keep --keep-dir C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA -maxrregcount=0 --machine 64 --compile -cudart static -Xcudafe "--diag_suppress=field_without_dll_interface" -Xcompiler "/wd 4819" -use_fast_math -DNO_SYNC -DWIN32 -D_WINDOWS -D_USRDLL -DMATH_EXPORTS -DUSE_CUDNN -D_UNICODE -DUNICODE -DNDEBUG -Xcompiler "/EHsc /W4 /nologo /O2 /FS /Zi /MD " -o C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA\GPUMatrix.cu.obj "C:\cntk\cntk\Source\Math\GPUMatrix.cu" 1> GPUTensor.cu 1>c:\src\cub-1.5.4\cub\util_allocator.cuh(700): error C2220: warning treated as error - no 'object' file generated 1>c:\src\cub-1.5.4\cub\util_allocator.cuh(700): warning C4512: 'cub::CachingDeviceAllocator' : assignment operator could not be generated 1> c:\src\cub-1.5.4\cub\util_allocator.cuh(101) : see declaration of 'cub::CachingDeviceAllocator' 1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\BuildCustomizations\CUDA 8.0.targets(687,9): error MSB3721: The command ""C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\bin\nvcc.exe" -gencode=arch=compute_30,code="sm_30,compute_30" -gencode=arch=compute_35,code="sm_35,compute_35" -gencode=arch=compute_50,code="sm_50,compute_50" --use-local-env --cl-version 2013 -Xcompiler /WX -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64" -IC:\cntk\cntk\Source\Common\include -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -I"c:\src\cub-1.5.4\" -I"C:\NVIDIA\cudnn-5.1\cuda\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" --source-in-ptx -lineinfo --keep --keep-dir C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA -maxrregcount=0 --machine 64 --compile -cudart static -Xcudafe "--diag_suppress=field_without_dll_interface" -Xcompiler "/wd 4819" -use_fast_math -DNO_SYNC -DWIN32 -D_WINDOWS -D_USRDLL -DMATH_EXPORTS -DUSE_CUDNN -D_UNICODE -DUNICODE -DNDEBUG -Xcompiler "/EHsc /W4 /nologo /O2 /FS /Zi /MD " -o C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA\GPUTensor.cu.obj "C:\cntk\cntk\Source\Math\GPUTensor.cu"" exited with code 2. 1> Skipping CUDA source file GPUMatrixCUDAKernels.cuh (excluded from build). 1> GPUMatrix.cu 1>c:\src\cub-1.5.4\cub\util_allocator.cuh(700): error C2220: warning treated as error - no 'object' file generated 1>c:\src\cub-1.5.4\cub\util_allocator.cuh(700): warning C4512: 'cub::CachingDeviceAllocator' : assignment operator could not be generated 1> c:\src\cub-1.5.4\cub\util_allocator.cuh(101) : see declaration of 'cub::CachingDeviceAllocator' 1>c:\src\cub-1.5.4\cub\device\dispatch/dispatch_radix_sort.cuh(1154): warning C4512: 'cub::DispatchRadixSort<true,KeyT,ValueT,int>' : assignment operator could not be generated 1> with 1> [ 1> KeyT=float 1> , ValueT=uint64_t 1> ] 1> c:\src\cub-1.5.4\cub\device/device_radix_sort.cuh(347) : see reference to class template instantiation 'cub::DispatchRadixSort<true,KeyT,ValueT,int>' being compiled 1> with 1> [ 1> KeyT=float 1> , ValueT=uint64_t 1> ] 1> C:/cntk/cntk/Source/Math/GPUMatrix.cu(2801) : see reference to function template instantiation 'cudaError_t cub::DeviceRadixSort::SortPairsDescending<ElemType,uint64_t>(void *,size_t &,KeyT *,KeyT *,ValueT *,ValueT *,int,int,int,cudaStream_t,bool)' being compiled 1> with 1> [ 1> ElemType=float 1> , KeyT=float 1> , ValueT=uint64_t 1> ] 1> C:/cntk/cntk/Source/Math/GPUMatrix.cu(2761) : while compiling class template member function 'void Microsoft::MSR::CNTK::GPUMatrix::VectorMax(Microsoft::MSR::CNTK::GPUMatrix &,Microsoft::MSR::CNTK::GPUMatrix &,const bool,int) const' 1> C:/cntk/cntk/Source/Math/GPUMatrix.cu(4543) : see reference to class template instantiation 'Microsoft::MSR::CNTK::GPUMatrix' being compiled 1>c:\src\cub-1.5.4\cub\device\dispatch/dispatch_radix_sort.cuh(1154): warning C4512: 'cub::DispatchRadixSort<false,KeyT,ValueT,int>' : assignment operator could not be generated 1> with 1> [ 1> KeyT=uint64_t 1> , ValueT=float 1> ] 1> c:\src\cub-1.5.4\cub\device/device_radix_sort.cuh(166) : see reference to class template instantiation 'cub::DispatchRadixSort<false,KeyT,ValueT,int>' being compiled 1> with 1> [ 1> KeyT=uint64_t 1> , ValueT=float 1> ] 1> C:/cntk/cntk/Source/Math/GPUMatrix.cu(2805) : see reference to function template instantiation 'cudaError_t cub::DeviceRadixSort::SortPairs<uint64_t,ElemType>(void *,size_t &,KeyT *,KeyT *,ValueT *,ValueT *,int,int,int,cudaStream_t,bool)' being compiled 1> with 1> [ 1> ElemType=float 1> , KeyT=uint64_t 1> , ValueT=float 1> ] 1>c:\src\cub-1.5.4\cub\device\dispatch/dispatch_radix_sort.cuh(1154): warning C4512: 'cub::DispatchRadixSort<true,KeyT,ValueT,int>' : assignment operator could not be generated 1> with 1> [ 1> KeyT=double 1> , ValueT=uint64_t 1> ] 1> c:\src\cub-1.5.4\cub\device/device_radix_sort.cuh(347) : see reference to class template instantiation 'cub::DispatchRadixSort<true,KeyT,ValueT,int>' being compiled 1> with 1> [ 1> KeyT=double 1> , ValueT=uint64_t 1> ] 1> C:/cntk/cntk/Source/Math/GPUMatrix.cu(2801) : see reference to function template instantiation 'cudaError_t cub::DeviceRadixSort::SortPairsDescending<ElemType,uint64_t>(void *,size_t &,KeyT *,KeyT *,ValueT *,ValueT *,int,int,int,cudaStream_t,bool)' being compiled 1> with 1> [ 1> ElemType=double 1> , KeyT=double 1> , ValueT=uint64_t 1> ] 1> C:/cntk/cntk/Source/Math/GPUMatrix.cu(2761) : while compiling class template member function 'void Microsoft::MSR::CNTK::GPUMatrix::VectorMax(Microsoft::MSR::CNTK::GPUMatrix &,Microsoft::MSR::CNTK::GPUMatrix &,const bool,int) const' 1> C:/cntk/cntk/Source/Math/GPUMatrix.cu(4544) : see reference to class template instantiation 'Microsoft::MSR::CNTK::GPUMatrix' being compiled 1>c:\src\cub-1.5.4\cub\device\dispatch/dispatch_radix_sort.cuh(1154): warning C4512: 'cub::DispatchRadixSort<false,KeyT,ValueT,int>' : assignment operator could not be generated 1> with 1> [ 1> KeyT=uint64_t 1> , ValueT=double 1> ] 1> c:\src\cub-1.5.4\cub\device/device_radix_sort.cuh(166) : see reference to class template instantiation 'cub::DispatchRadixSort<false,KeyT,ValueT,int>' being compiled 1> with 1> [ 1> KeyT=uint64_t 1> , ValueT=double 1> ] 1> C:/cntk/cntk/Source/Math/GPUMatrix.cu(2805) : see reference to function template instantiation 'cudaError_t cub::DeviceRadixSort::SortPairs<uint64_t,ElemType>(void *,size_t &,KeyT *,KeyT *,ValueT *,ValueT *,int,int,int,cudaStream_t,bool)' being compiled 1> with 1> [ 1> ElemType=double 1> , KeyT=uint64_t 1> , ValueT=double 1> ] 1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\BuildCustomizations\CUDA 8.0.targets(687,9): error MSB3721: The command ""C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\bin\nvcc.exe" -gencode=arch=compute_30,code="sm_30,compute_30" -gencode=arch=compute_35,code="sm_35,compute_35" -gencode=arch=compute_50,code="sm_50,compute_50" --use-local-env --cl-version 2013 -Xcompiler /WX -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64" -IC:\cntk\cntk\Source\Common\include -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -I"c:\src\cub-1.5.4\" -I"C:\NVIDIA\cudnn-5.1\cuda\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\include" -lineinfo --keep --keep-dir C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA -maxrregcount=0 --machine 64 --compile -cudart static -Xcudafe "--diag_suppress=field_without_dll_interface" -Xcompiler "/wd 4819" -use_fast_math -DNO_SYNC -DWIN32 -D_WINDOWS -D_USRDLL -DMATH_EXPORTS -DUSE_CUDNN -D_UNICODE -DUNICODE -DNDEBUG -Xcompiler "/EHsc /W4 /nologo /O2 /FS /Zi /MD " -o C:\cntk\cntk\x64.build\Release\Source\Math\MathCUDA\GPUMatrix.cu.obj "C:\cntk\cntk\Source\Math\GPUMatrix.cu"" exited with code 2.

clintjcampbell avatar Nov 10 '16 04:11 clintjcampbell

Could you try with cub-1.4.1(https://github.com/Microsoft/CNTK/wiki/Setup-CNTK-on-Windows#cub)?

raaaar avatar Nov 10 '16 08:11 raaaar

Hey @clintjcampbell , can you try again with latest master? We've today merged a CUDA 8 build fix (see #1023).

Thanks, Mark

mahilleb-msft avatar Nov 11 '16 11:11 mahilleb-msft

Thanks. That fixed it.

On Nov 11, 2016 3:47 AM, "Mark Hillebrand" [email protected] wrote:

Hey @clintjcampbell https://github.com/clintjcampbell , can you try again with latest master? We've today merged a CUDA 8 build fix (see #1023 https://github.com/Microsoft/CNTK/pull/1023).

Thanks, Mark

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Microsoft/CNTK/issues/1018#issuecomment-259941147, or mute the thread https://github.com/notifications/unsubscribe-auth/AP7KUWChZKhTonoazWi9aitchfjo5cIbks5q9FXMgaJpZM4KuRnG .

clintjcampbell avatar Nov 11 '16 14:11 clintjcampbell

Hello mahilleb, I am trying to compile CNTK v2 on a gtx 1080, and throwing piles of errors (39). Does the CNTK v3 Beta auto-install support the 1080 yet, and what are the changes to scripts to use CUDA 8?

Thanks for any help. Andrew

amzador2 avatar Nov 14 '16 19:11 amzador2

What's your operating system and compiler version?

n17s avatar Nov 16 '16 00:11 n17s

Hello Nikos,

Thanks for your assistance.

I am running MS Windows 8.1 Pro x64 Version 6.3.9600 Build 9600 MS Visual Studio Professional 2013 with Update 5 There is also a VS 2010 Tools for Office Runtime (x64) MS MPI (7.1.12437.25) Python 3.5.2 (Anaconda 3 4.1.1 64 bit) NVidia CUDA Development 8 and VS Integration 8.0

I am running on an Asus Z170A motherboard with Intel Core i7-6700K CPU @ 4.01 GHz 16 GB RAM MSI Sea Hawk GTX 1080

The latest self-install update, CNTK-2-0-beta3-0-Windows-64bit-GPU.zip was coaxed into running last night. I could not disentangle the complexities of the CNTK compile process on the previous version, and the GTX 1080 required CUDA 8 and Cudnn 1.5.5.

Thanks for any insights into CNTK and the dependencies of the projects.

Best regards, Andrew


SUBJECT: Re: [Microsoft/CNTK] issue compiling MathCUDA with CUDA 8.0 (#1018) DATE: Tue, 15 Nov 2016 16:48:40 -0800 FROM: Nikos Karampatziakis

TO: Microsoft/CNTK CC: amzador2 , Comment REPLY-TO: Microsoft/CNTK

What's you operating system and compiler version?

You are receiving this because you commented. Reply to this email directly, view it on GitHub [1], or mute the thread [2].

Links:

[1] https://github.com/Microsoft/CNTK/issues/1018#issuecomment-260818719 [2] https://github.com/notifications/unsubscribe-auth/AWIZxEmgz43QLr5Gyunh1gNVZ0x8CK9cks5q-lLogaJpZM4KuRnG

amzador2 avatar Nov 17 '16 02:11 amzador2

Have you set the environment variables mentioned here?

n17s avatar Nov 18 '16 02:11 n17s