CUPTI User's Guide
CUPTI User's Guide
CUPTI User's Guide
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
<strong>CUPTI</strong>The CUDA Profiling Tools Interface (<strong>CUPTI</strong>) enables the creation of profiling and tracingtools that target CUDA applications. <strong>CUPTI</strong> provides four APIs, the Activity API, theCallback API, the Event API, and the Metric API. Using these APIs, you can developprofiling tools that give insight into the CPU and GPU behavior of CUDA applications.<strong>CUPTI</strong> is delivered as a dynamic library on all platforms supported by CUDA.<strong>CUPTI</strong> Compatibility and RequirementsNew versions of the CUDA driver are backwards compatible with older versions of <strong>CUPTI</strong>.For example, a developer using a profiling tool based on <strong>CUPTI</strong> 4.0 can update theirCUDA driver to 4.1. However, new versions of <strong>CUPTI</strong> are not backwards compatible witholder versions of the CUDA driver. For example, a developer using a profiling tool basedon <strong>CUPTI</strong> 4.1 must have the 4.1 version of the CUDA driver (or later) installed as well.<strong>CUPTI</strong> calls will fail with <strong>CUPTI</strong>_ERROR_NOT_INITIALIZED if the CUDA driver version isnot compatible with the <strong>CUPTI</strong> version.<strong>CUPTI</strong> Initialization<strong>CUPTI</strong> initialization occurs lazily the first time you invoke any <strong>CUPTI</strong> function. The theEvent, Metric, and Callback APIs there are no requirements on when this initializationmust occur (i.e. you can invoke the first <strong>CUPTI</strong> function at any point). For correctoperation, the Activity API does require that <strong>CUPTI</strong> be initialized before any CUDAdriver or runtime API is invoked. See the <strong>CUPTI</strong> Activity API section for moreinformation on <strong>CUPTI</strong> initialization requirements for the activity API.CUDA Tools SDK <strong>CUPTI</strong> User’s <strong>Guide</strong> DA-05679-001_v01 | 3