Questions tagged [nvcc]

"nvcc" is NVIDIA's LLVM-based C/C++ compiler for targeting GPUs with CUDA.

This tag refers to NVIDIA’s compiler toolchain nvcc for the parallel computing architecture (CUDA). Documentation for nvcc is included with the CUDA Toolkit.

You should ask questions about CUDA here on Stack Overflow, but if you have bugs to report you should discuss them on the CUDA forums or report them via the registered developer portal. You may want to cross-link to any discussion here on Stack Overflow.

688 questions
5
votes
1 answer

Cons of virtual methods in cuda

So far as I understand, virtual method calls are late binding and thus cannot be inlined by the compiler. Apparently, nvcc relies heavily on inlining code. I'm wondering if virtual methods have any serious disadvantage if used in a kernel in Cuda.…
eaponte
  • 409
  • 5
  • 15
5
votes
1 answer

Hello World CUDA compilation issues

I'm using the CUDA by Example book and attempting to compile the first real example in the book. I'm on OSX 10.9.2: My source is: @punk ~/Documents/Projects/CUDA$ /Developer/NVIDIA/CUDA-6.0/bin/nvcc hello.c nvcc warning : The 'compute_10' and…
mr-sk
  • 13,174
  • 11
  • 66
  • 101
5
votes
1 answer

"don't know what to do with' nvcc fatal error

I use the command lines in Ubuntu's terminal. And I am trying to compile the three files presented in CUDA_Compiler_Driver_NVCC.pdf When I do use the command line given by the documentation on these 3 files, I do get the following errors: nvcc…
Gibo
  • 61
  • 1
  • 4
5
votes
1 answer

When to use volatile with register/local variables

What is the meaning of declaring register arrays in CUDA with volatile qualifier? When I tried with volatile keyword with a register array, it removed the number of spilled register memory to local memory. (i.e. Force the CUDA to use registers…
warunapww
  • 966
  • 4
  • 18
  • 38
5
votes
3 answers

CUDA nvcc compiler setup Ubuntu 12.04

I successfully installed the nvidia driver and toolkit for cuda 5 (but not the samples) on a 64 bit Ubuntu 12.04 box. The samples failed to install even though I previously ran $ sudo apt-get install freeglut3-dev build-essential libx11-dev…
andandandand
  • 21,946
  • 60
  • 170
  • 271
5
votes
1 answer

nvcc: command not found

I installed cuda sdk 5.0 to /opt and even compiled all examples, but I can't execute nvcc. Here is some console output: I'm using linux mint 13.
user983302
  • 1,377
  • 3
  • 14
  • 23
5
votes
1 answer

Does -use-fast-math option translate SP multiplications to intrinsics?

I had a quick glance of the CUDA Programming guide w.r.t -use-fast-math optimizations, and although appendix C mention divisions to be converted to an intrinsic but there are no mention of multiplications. The reason I ask this question is, my…
Sayan
  • 2,662
  • 10
  • 41
  • 56
5
votes
0 answers

QtCreator's qmake with nvcc and CUDA, Windows 7

I've seen many old tries to combine QtCreator with CUDA, but they all don't work anymore. So I'm starting this topic so that there could be a new reference for everyone. First, I tried to compile the code like the book mentions, with the following…
user1442235
5
votes
1 answer

pycuda; nvcc fatal : Visual Studio configuration file '(null)' could not be found

I'm trying to run pycuda introductory tutorial after installing Visual C++ Express 2010 and all kinds of Nvidia drivers, SDK, etc. I get to mod = SourceModule(""" __global__ void doublify(float *a) { int idx = threadIdx.x + threadIdx.y*4; a[idx] *=…
Konsta
  • 347
  • 4
  • 18
4
votes
2 answers

Default host compiler used by nvcc for linux

I am using CUDA 4.0 on Ubuntu 10.10 with GTX 570 (compute capcability 2.0), with the GCC compiler suite. As I understand it, during compilation the CUDA compiler driver nvcc splits the .cu files into host code and device code and calls the host…
smilingbuddha
  • 14,334
  • 33
  • 112
  • 189
4
votes
1 answer

Why does nvcc fails to compile a CUDA file with boost::spirit?

I'm trying to integrate CUDA to an existing aplication wich uses boost::spirit. Isolating the problem, I've found out that the following code does not copile with nvcc: main.cu: #include int main(){ …
Vik
  • 133
  • 2
  • 10
4
votes
1 answer

calling a __host__ function from a __host__ __device__ function

When compiling the MWE #include #include "cuda.h" struct Foo{ ///* Foo( ){ std::cout << "Construct" << std::endl; } Foo( const Foo & that ){ std::cout << "Copy construct" << std::endl; } //*/ __host__…
4
votes
1 answer

CMake passes C++ arguments to nvcc

I'm working on a project that mixes C++ and CUDA. In addition it links 3rd party libraries, specifically we suspect this problem comes from aws-sdk-c++. The problem is that when we link against our libraries that uses AWS, a -pthread flag is added…
La bla bla
  • 8,558
  • 13
  • 60
  • 109
4
votes
0 answers

How can I compile CUDA C-code with Cython on Windows?

I would like to include several CUDA accelearated functions into Python. Therefore, I was looking into Cython. However, how can I tell Cython to use the nvcc Compiler? I have the following C code in the file hello.c: #include #include…
P. Egli
  • 167
  • 1
  • 4
4
votes
1 answer

nvprof command error: cupti64_102.dll was not found

When I try to run nvprof command in Command Prompt, System Erros pops up and says "The code execution cannot proceed because cupti64_102.dll was not found. Reinstall the program may fix this problem." I have installed the CUDA Toolkit 10.2 but…
john mori
  • 41
  • 1
  • 2