12.07.2015 Views

NVIDIA CUDA

NVIDIA CUDA

NVIDIA CUDA

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

3.20 Context Management 1073.20.2.7 CUresult cuCtxPushCurrent (CUcontext NewCtx)Pushes the given context NewCtx onto the CPU thread’s stack of current contexts. The specified context becomes theCPU thread’s current context, so all <strong>CUDA</strong> functions that operate on the current context are affected.The previous current context may be made current again by calling cuCtxDestroy() or cuCtxPopCurrent().The context must be "floating," i.e. not attached to any thread. Contexts are made to float by calling cuCtxPopCurrent().Parameters:NewCtx - Floating context to attachReturns:Note:<strong>CUDA</strong>_SUCCESS, <strong>CUDA</strong>_ERROR_DEINITIALIZED, <strong>CUDA</strong>_ERROR_NOT_INITIALIZED, <strong>CUDA</strong>_-ERROR_INVALID_CONTEXT, <strong>CUDA</strong>_ERROR_INVALID_VALUESee also:Note that this function may also return error codes from previous, asynchronous launches.cuCtxAttach, cuCtxCreate, cuCtxDestroy, cuCtxDetach, cuCtxGetDevice, cuCtxPopCurrent, cuCtxSynchronize3.20.2.8 CUresult cuCtxSynchronize (void)Blocks until the device has completed all preceding requested tasks. cuCtxSynchronize() returns an error if one of thepreceding tasks failed.Returns:Note:<strong>CUDA</strong>_SUCCESS, <strong>CUDA</strong>_ERROR_DEINITIALIZED, <strong>CUDA</strong>_ERROR_NOT_INITIALIZED, <strong>CUDA</strong>_-ERROR_INVALID_CONTEXTSee also:Note that this function may also return error codes from previous, asynchronous launches.cuCtxAttach, cuCtxCreate, cuCtxDestroy, cuCtxDetach, cuCtxGetDevice, cuCtxPopCurrent, cuCtxSynchronizeGenerated on Wed Apr 1 16:11:42 2009 for <strong>NVIDIA</strong> <strong>CUDA</strong> Library by Doxygen

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!