where to find the definition of those function ?

In the appendix of Programming Guide, there are many functions, such as Atomic functions, runtime API reference and High-level API,etc. but where can we find the definition of those functions? for example, when I use AtomicAdd in a program, but the compiler said this function is not defined, same to the texture management functions. can any one knows the answer?

thanks for any reply.

Device functions are declared in “device_functions.h”, which is included from “cuda_runtime.h”, so you probably need to include cuda_runtime.h in your .cu files.

the function AtomicAdd is defined in sm_11_atomic_functions.h, but when I include it in my file, the compiler also say that the atomicAdd is undefined. why this error accur?

To compile code using atomic functions you must add the option “-arch sm_11” to the nvcc command line.

Atomics are only supported on Compute 1.1 devices (GeForce 8400/8500/8600).

Then, how to add the option to the command line? in the attribute option of .cu file? and how do I get the information about whether my graphics card support Atomics? my card is Quadro FX 5600.

The quadro cards are 8800, so has compute program 1.0. Alas, no atomic operations.