Sophie

Sophie

distrib > Mageia > 7 > x86_64 > media > nonfree-updates > by-pkgid > b86a85131cc739c1c53d0b55840a4328 > files > 1383

nvidia-cuda-toolkit-devel-10.1.168-1.2.mga7.nonfree.x86_64.rpm

<!DOCTYPE html
  PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-us" xml:lang="en-us">
   <head>
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8"></meta>
      <meta http-equiv="X-UA-Compatible" content="IE=edge"></meta>
      <meta name="copyright" content="(C) Copyright 2005"></meta>
      <meta name="DC.rights.owner" content="(C) Copyright 2005"></meta>
      <meta name="DC.Type" content="cppModule"></meta>
      <meta name="DC.Title" content="Event Management"></meta>
      <meta name="abstract" content=""></meta>
      <meta name="description" content=""></meta>
      <meta name="DC.Format" content="XHTML"></meta>
      <meta name="DC.Identifier" content="group__CUDA__EVENT"></meta>
      <link rel="stylesheet" type="text/css" href="../common/formatting/commonltr.css"></link>
      <link rel="stylesheet" type="text/css" href="../common/formatting/site.css"></link>
      <title>CUDA Driver API :: CUDA Toolkit Documentation</title>
      <!--[if lt IE 9]>
      <script src="../common/formatting/html5shiv-printshiv.min.js"></script>
      <![endif]-->
      <script type="text/javascript" charset="utf-8" src="//assets.adobedtm.com/b92787824f2e0e9b68dc2e993f9bd995339fe417/satelliteLib-7ba51e58dc61bcb0e9311aadd02a0108ab24cc6c.js"></script>
      <script type="text/javascript" charset="utf-8" src="../common/formatting/jquery.min.js"></script>
      <script type="text/javascript" charset="utf-8" src="../common/formatting/jquery.ba-hashchange.min.js"></script>
      <script type="text/javascript" charset="utf-8" src="../common/formatting/jquery.scrollintoview.min.js"></script>
      <script type="text/javascript" src="../search/htmlFileList.js"></script>
      <script type="text/javascript" src="../search/htmlFileInfoList.js"></script>
      <script type="text/javascript" src="../search/nwSearchFnt.min.js"></script>
      <script type="text/javascript" src="../search/stemmers/en_stemmer.min.js"></script>
      <script type="text/javascript" src="../search/index-1.js"></script>
      <script type="text/javascript" src="../search/index-2.js"></script>
      <script type="text/javascript" src="../search/index-3.js"></script>
      <link rel="canonical" href="http://docs.nvidia.com/cuda/cuda-driver-api/index.html"></link>
      <link rel="stylesheet" type="text/css" href="../common/formatting/qwcode.highlight.css"></link>
   </head>
   <body>
      
      <header id="header"><span id="company">NVIDIA</span><span id="site-title">CUDA Toolkit Documentation</span><form id="search" method="get" action="search">
            <input type="text" name="search-text"></input><fieldset id="search-location">
               <legend>Search In:</legend>
               <label><input type="radio" name="search-type" value="site"></input>Entire Site</label>
               <label><input type="radio" name="search-type" value="document"></input>Just This Document</label></fieldset>
            <button type="reset">clear search</button>
            <button id="submit" type="submit">search</button></form>
      </header>
      <div id="site-content">
         <nav id="site-nav">
            <div class="category closed"><a href="../index.html" title="The root of the site.">CUDA Toolkit 
                  
                  
                  v10.1.168</a></div>
            <div class="category"><a href="index.html" title="CUDA Driver API">CUDA Driver API</a></div>
            <ul>
               <li>
                  <div class="section-link"><a href="driver-vs-runtime-api.html#driver-vs-runtime-api">1.&nbsp;Difference between the driver and runtime APIs </a></div>
               </li>
               <li>
                  <div class="section-link"><a href="api-sync-behavior.html#api-sync-behavior">2.&nbsp;API synchronization behavior </a></div>
               </li>
               <li>
                  <div class="section-link"><a href="stream-sync-behavior.html#stream-sync-behavior">3.&nbsp;Stream synchronization behavior</a></div>
               </li>
               <li>
                  <div class="section-link"><a href="graphs-thread-safety.html#graphs-thread-safety">4.&nbsp;Graph object thread safety</a></div>
               </li>
               <li>
                  <div class="section-link"><a href="modules.html#modules">5.&nbsp;Modules</a></div>
                  <ul>
                     <li>
                        <div class="section-link"><a href="group__CUDA__TYPES.html#group__CUDA__TYPES">5.1.&nbsp;Data types used by CUDA driver</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__ERROR.html#group__CUDA__ERROR">5.2.&nbsp;Error Handling</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__INITIALIZE.html#group__CUDA__INITIALIZE">5.3.&nbsp;Initialization</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__VERSION.html#group__CUDA__VERSION">5.4.&nbsp;Version Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__DEVICE.html#group__CUDA__DEVICE">5.5.&nbsp;Device Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__DEVICE__DEPRECATED.html#group__CUDA__DEVICE__DEPRECATED">5.6.&nbsp;Device Management [DEPRECATED]</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__PRIMARY__CTX.html#group__CUDA__PRIMARY__CTX">5.7.&nbsp;Primary Context Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__CTX.html#group__CUDA__CTX">5.8.&nbsp;Context Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__CTX__DEPRECATED.html#group__CUDA__CTX__DEPRECATED">5.9.&nbsp;Context Management [DEPRECATED]</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__MODULE.html#group__CUDA__MODULE">5.10.&nbsp;Module Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__MEM.html#group__CUDA__MEM">5.11.&nbsp;Memory Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED">5.12.&nbsp;Unified Addressing</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__STREAM.html#group__CUDA__STREAM">5.13.&nbsp;Stream Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__EVENT.html#group__CUDA__EVENT">5.14.&nbsp;Event Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__EXTRES__INTEROP.html#group__CUDA__EXTRES__INTEROP">5.15.&nbsp;External Resource Interoperability</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__MEMOP.html#group__CUDA__MEMOP">5.16.&nbsp;Stream memory operations</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__EXEC.html#group__CUDA__EXEC">5.17.&nbsp;Execution Control</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__EXEC__DEPRECATED.html#group__CUDA__EXEC__DEPRECATED">5.18.&nbsp;Execution Control [DEPRECATED]</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__GRAPH.html#group__CUDA__GRAPH">5.19.&nbsp;Graph Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__OCCUPANCY.html#group__CUDA__OCCUPANCY">5.20.&nbsp;Occupancy</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__TEXREF__DEPRECATED.html#group__CUDA__TEXREF__DEPRECATED">5.21.&nbsp;Texture Reference Management [DEPRECATED]</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__SURFREF__DEPRECATED.html#group__CUDA__SURFREF__DEPRECATED">5.22.&nbsp;Surface Reference Management [DEPRECATED]</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__TEXOBJECT.html#group__CUDA__TEXOBJECT">5.23.&nbsp;Texture Object Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__SURFOBJECT.html#group__CUDA__SURFOBJECT">5.24.&nbsp;Surface Object Management</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__PEER__ACCESS.html#group__CUDA__PEER__ACCESS">5.25.&nbsp;Peer Context Memory Access</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__GRAPHICS.html#group__CUDA__GRAPHICS">5.26.&nbsp;Graphics Interoperability</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__PROFILER.html#group__CUDA__PROFILER">5.27.&nbsp;Profiler Control</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__GL.html#group__CUDA__GL">5.28.&nbsp;OpenGL Interoperability</a></div>
                        <ul>
                           <li>
                              <div class="section-link"><a href="group__CUDA__GL__DEPRECATED.html#group__CUDA__GL__DEPRECATED">5.28.1.&nbsp;OpenGL Interoperability [DEPRECATED]</a></div>
                           </li>
                        </ul>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__D3D9.html#group__CUDA__D3D9">5.29.&nbsp;Direct3D 9 Interoperability</a></div>
                        <ul>
                           <li>
                              <div class="section-link"><a href="group__CUDA__D3D9__DEPRECATED.html#group__CUDA__D3D9__DEPRECATED">5.29.1.&nbsp;Direct3D 9 Interoperability [DEPRECATED]</a></div>
                           </li>
                        </ul>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__D3D10.html#group__CUDA__D3D10">5.30.&nbsp;Direct3D 10 Interoperability</a></div>
                        <ul>
                           <li>
                              <div class="section-link"><a href="group__CUDA__D3D10__DEPRECATED.html#group__CUDA__D3D10__DEPRECATED">5.30.1.&nbsp;Direct3D 10 Interoperability [DEPRECATED]</a></div>
                           </li>
                        </ul>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__D3D11.html#group__CUDA__D3D11">5.31.&nbsp;Direct3D 11 Interoperability</a></div>
                        <ul>
                           <li>
                              <div class="section-link"><a href="group__CUDA__D3D11__DEPRECATED.html#group__CUDA__D3D11__DEPRECATED">5.31.1.&nbsp;Direct3D 11 Interoperability [DEPRECATED]</a></div>
                           </li>
                        </ul>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__VDPAU.html#group__CUDA__VDPAU">5.32.&nbsp;VDPAU Interoperability</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="group__CUDA__EGL.html#group__CUDA__EGL">5.33.&nbsp;EGL Interoperability</a></div>
                     </li>
                  </ul>
               </li>
               <li>
                  <div class="section-link"><a href="annotated.html#annotated">6.&nbsp;Data Structures</a></div>
                  <ul>
                     <li>
                        <div class="section-link"><a href="structCUDA__ARRAY3D__DESCRIPTOR.html#structCUDA__ARRAY3D__DESCRIPTOR">6.1.&nbsp;CUDA_ARRAY3D_DESCRIPTOR</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__ARRAY__DESCRIPTOR.html#structCUDA__ARRAY__DESCRIPTOR">6.2.&nbsp;CUDA_ARRAY_DESCRIPTOR</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__EXTERNAL__MEMORY__BUFFER__DESC.html#structCUDA__EXTERNAL__MEMORY__BUFFER__DESC">6.3.&nbsp;CUDA_EXTERNAL_MEMORY_BUFFER_DESC</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__EXTERNAL__MEMORY__HANDLE__DESC.html#structCUDA__EXTERNAL__MEMORY__HANDLE__DESC">6.4.&nbsp;CUDA_EXTERNAL_MEMORY_HANDLE_DESC</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__EXTERNAL__MEMORY__MIPMAPPED__ARRAY__DESC.html#structCUDA__EXTERNAL__MEMORY__MIPMAPPED__ARRAY__DESC">6.5.&nbsp;CUDA_EXTERNAL_MEMORY_MIPMAPPED_ARRAY_DESC</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__EXTERNAL__SEMAPHORE__HANDLE__DESC.html#structCUDA__EXTERNAL__SEMAPHORE__HANDLE__DESC">6.6.&nbsp;CUDA_EXTERNAL_SEMAPHORE_HANDLE_DESC</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__EXTERNAL__SEMAPHORE__SIGNAL__PARAMS.html#structCUDA__EXTERNAL__SEMAPHORE__SIGNAL__PARAMS">6.7.&nbsp;CUDA_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__EXTERNAL__SEMAPHORE__WAIT__PARAMS.html#structCUDA__EXTERNAL__SEMAPHORE__WAIT__PARAMS">6.8.&nbsp;CUDA_EXTERNAL_SEMAPHORE_WAIT_PARAMS</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__HOST__NODE__PARAMS.html#structCUDA__HOST__NODE__PARAMS">6.9.&nbsp;CUDA_HOST_NODE_PARAMS</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__KERNEL__NODE__PARAMS.html#structCUDA__KERNEL__NODE__PARAMS">6.10.&nbsp;CUDA_KERNEL_NODE_PARAMS</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__LAUNCH__PARAMS.html#structCUDA__LAUNCH__PARAMS">6.11.&nbsp;CUDA_LAUNCH_PARAMS</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__MEMCPY2D.html#structCUDA__MEMCPY2D">6.12.&nbsp;CUDA_MEMCPY2D</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__MEMCPY3D.html#structCUDA__MEMCPY3D">6.13.&nbsp;CUDA_MEMCPY3D</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__MEMCPY3D__PEER.html#structCUDA__MEMCPY3D__PEER">6.14.&nbsp;CUDA_MEMCPY3D_PEER</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__MEMSET__NODE__PARAMS.html#structCUDA__MEMSET__NODE__PARAMS">6.15.&nbsp;CUDA_MEMSET_NODE_PARAMS</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__POINTER__ATTRIBUTE__P2P__TOKENS.html#structCUDA__POINTER__ATTRIBUTE__P2P__TOKENS">6.16.&nbsp;CUDA_POINTER_ATTRIBUTE_P2P_TOKENS</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__RESOURCE__DESC.html#structCUDA__RESOURCE__DESC">6.17.&nbsp;CUDA_RESOURCE_DESC</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__RESOURCE__VIEW__DESC.html#structCUDA__RESOURCE__VIEW__DESC">6.18.&nbsp;CUDA_RESOURCE_VIEW_DESC</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUDA__TEXTURE__DESC.html#structCUDA__TEXTURE__DESC">6.19.&nbsp;CUDA_TEXTURE_DESC</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUdevprop.html#structCUdevprop">6.20.&nbsp;CUdevprop</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUeglFrame.html#structCUeglFrame">6.21.&nbsp;CUeglFrame</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUipcEventHandle.html#structCUipcEventHandle">6.22.&nbsp;CUipcEventHandle</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="structCUipcMemHandle.html#structCUipcMemHandle">6.23.&nbsp;CUipcMemHandle</a></div>
                     </li>
                     <li>
                        <div class="section-link"><a href="unionCUstreamBatchMemOpParams.html#unionCUstreamBatchMemOpParams">6.24.&nbsp;CUstreamBatchMemOpParams</a></div>
                     </li>
                  </ul>
               </li>
               <li>
                  <div class="section-link"><a href="functions.html#functions">7.&nbsp;Data Fields</a></div>
               </li>
               <li>
                  <div class="section-link"><a href="deprecated.html#deprecated">8.&nbsp;Deprecated List</a></div>
               </li>
               <li>
                  <div class="section-link"><a href="notices-header.html#notices-header">Notices</a></div>
                  <ul></ul>
               </li>
            </ul>
         </nav>
         <div id="resize-nav"></div>
         <nav id="search-results">
            <h2>Search Results</h2>
            <ol></ol>
         </nav>
         
         <div id="contents-container">
            <div id="breadcrumbs-container">
               <div id="breadcrumbs"><a href="group__CUDA__STREAM.html" shape="rect">&lt; Previous</a> | <a href="group__CUDA__EXTRES__INTEROP.html" shape="rect">Next &gt;</a></div>
               <div id="release-info">CUDA Driver API
                  (<a href="../../pdf/CUDA_Driver_API.pdf">PDF</a>)
                  -
                   
                  
                  
                  v10.1.168
                  (<a href="https://developer.nvidia.com/cuda-toolkit-archive">older</a>)
                  -
                  Last updated April 24, 2019
                  -
                  <a href="mailto:CUDAIssues@nvidia.com?subject=CUDA Toolkit Documentation Feedback: CUDA Driver API">Send Feedback</a></div>
            </div>
            <article id="contents">
               <div class="topic reference apiRef apiPackage cppModule" id="group__CUDA__EVENT"><a name="group__CUDA__EVENT" shape="rect">
                     <!-- --></a><h2 class="topictitle2 cppModule">5.14.&nbsp;Event Management</h2>
                  <div class="section">
                     <p>This section describes the event management functions of the low-level CUDA driver application programming interface. </p>
                  </div>
                  <h3 class="fake_sectiontitle member_header">Functions</h3>
                  <dl class="members">
                     <dt><span class="member_type"><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a>&nbsp;</span><span class="member_name"><a href="#group__CUDA__EVENT_1g450687e75f3ff992fe01662a43d9d3db" shape="rect">cuEventCreate</a> (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a>*<span>&nbsp;</span><span class="keyword keyword apiItemName">phEvent</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">Flags</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Creates an event. </span></dd>
                     <dt><span class="member_type"><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a>&nbsp;</span><span class="member_name"><a href="#group__CUDA__EVENT_1g593ec73a8ec5a5fc031311d3e4dca1ef" shape="rect">cuEventDestroy</a> (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEvent</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Destroys an event. </span></dd>
                     <dt><span class="member_type"><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a>&nbsp;</span><span class="member_name"><a href="#group__CUDA__EVENT_1gdfb1178807353bbcaa9e245da497cf97" shape="rect">cuEventElapsedTime</a> (  float*<span>&nbsp;</span><span class="keyword keyword apiItemName">pMilliseconds</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hStart</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEnd</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Computes the elapsed time between two events. </span></dd>
                     <dt><span class="member_type"><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a>&nbsp;</span><span class="member_name"><a href="#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" shape="rect">cuEventQuery</a> (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEvent</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Queries an event's status. </span></dd>
                     <dt><span class="member_type"><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a>&nbsp;</span><span class="member_name"><a href="#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" shape="rect">cuEventRecord</a> (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEvent</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gb946c7f02e09efd788a204718015d88a" title="" shape="rect">CUstream</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hStream</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Records an event. </span></dd>
                     <dt><span class="member_type"><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a>&nbsp;</span><span class="member_name"><a href="#group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" shape="rect">cuEventSynchronize</a> (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEvent</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Waits for an event to complete. </span></dd>
                  </dl>
                  <div class="description">
                     <h3 class="sectiontitle">Functions</h3>
                     <dl class="description">
                        <dt class="description"><a name="group__CUDA__EVENT_1g450687e75f3ff992fe01662a43d9d3db" id="group__CUDA__EVENT_1g450687e75f3ff992fe01662a43d9d3db" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuEventCreate (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a>*<span>&nbsp;</span><span class="keyword keyword apiItemName">phEvent</span>, unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">Flags</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Creates an event. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">phEvent</span></tt></dt>
                                 <dd>- Returns newly created event </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">Flags</span></tt></dt>
                                 <dd>- Event creation flags</dd>
                              </dl>
                           </div>
                           <div class="section">
                              <h6 class="return_header">Returns</h6>
                              <p class="return"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9acf52f132faf29b473cdda6061f0f44a" shape="rect">CUDA_ERROR_DEINITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e98feb999f0af99b4a25ab26b3866f4df8" shape="rect">CUDA_ERROR_NOT_INITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a484e9af32c1e9893ff21f0e0191a12d" shape="rect">CUDA_ERROR_INVALID_CONTEXT</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9264c50688ed110e8476b591befe60c02" shape="rect">CUDA_ERROR_OUT_OF_MEMORY</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Creates an event *phEvent for the current context with the flags specified via <tt class="ph tt code">Flags</tt>. Valid flags include:
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f629e22adf5df73b0d43c6374a12ebee1333" shape="rect">CU_EVENT_DEFAULT</a>: Default event creation flag.
                                       </p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f6296813b3b31fdb737133124f3c35044362" shape="rect">CU_EVENT_BLOCKING_SYNC</a>: Specifies that the created event should use blocking synchronization. A CPU thread that uses <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" title="Waits for an event to complete." shape="rect">cuEventSynchronize()</a> to wait on an event created with this flag will block until the event has actually been recorded.
                                       </p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f629daa5463f64794c10b78c603d23c0bff2" shape="rect">CU_EVENT_DISABLE_TIMING</a>: Specifies that the created event does not need to record timing data. Events created with this flag specified and the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f6296813b3b31fdb737133124f3c35044362" shape="rect">CU_EVENT_BLOCKING_SYNC</a> flag not specified will provide the best performance when used with <a class="xref" href="group__CUDA__STREAM.html#group__CUDA__STREAM_1g6a898b652dfc6aa1d5c8d97062618b2f" title="Make a compute stream wait on an event." shape="rect">cuStreamWaitEvent()</a> and <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery()</a>.
                                       </p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f629adab662356d24cf59f3d7de07c3cd52e" shape="rect">CU_EVENT_INTERPROCESS</a>: Specifies that the created event may be used as an interprocess event by <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gea02eadd12483de5305878b13288a86c" title="Gets an interprocess handle for a previously allocated event." shape="rect">cuIpcGetEventHandle()</a>. <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f629adab662356d24cf59f3d7de07c3cd52e" shape="rect">CU_EVENT_INTERPROCESS</a> must be specified along with <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f629daa5463f64794c10b78c603d23c0bff2" shape="rect">CU_EVENT_DISABLE_TIMING</a>.
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p"></p>
                              <p class="p"></p>
                              <p class="p">
                                 <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
                                 </div>
                              </p>
                              <p class="p"></p>
                              <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
                              <p class="p see_subsection"><a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" title="Waits for an event to complete." shape="rect">cuEventSynchronize</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g593ec73a8ec5a5fc031311d3e4dca1ef" title="Destroys an event." shape="rect">cuEventDestroy</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1gdfb1178807353bbcaa9e245da497cf97" title="Computes the elapsed time between two events." shape="rect">cuEventElapsedTime</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__HIGHLEVEL.html#group__CUDART__HIGHLEVEL_1g4b5fdb19d7fb5f6f8862559f9279f6c3" target="_blank" shape="rect">cudaEventCreate</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__EVENT.html#group__CUDART__EVENT_1g7b317e07ff385d85aa656204b971a042" target="_blank" shape="rect">cudaEventCreateWithFlags</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__EVENT_1g593ec73a8ec5a5fc031311d3e4dca1ef" id="group__CUDA__EVENT_1g593ec73a8ec5a5fc031311d3e4dca1ef" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuEventDestroy (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEvent</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Destroys an event. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">hEvent</span></tt></dt>
                                 <dd>- Event to destroy</dd>
                              </dl>
                           </div>
                           <div class="section">
                              <h6 class="return_header">Returns</h6>
                              <p class="return"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9acf52f132faf29b473cdda6061f0f44a" shape="rect">CUDA_ERROR_DEINITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e98feb999f0af99b4a25ab26b3866f4df8" shape="rect">CUDA_ERROR_NOT_INITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a484e9af32c1e9893ff21f0e0191a12d" shape="rect">CUDA_ERROR_INVALID_CONTEXT</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e90fd2e63260c6317ba943af0f7e4b8d21" shape="rect">CUDA_ERROR_INVALID_HANDLE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Destroys the event specified by <tt class="ph tt code">hEvent</tt>.
                              </p>
                              <p class="p">An event may be destroyed before it is complete (i.e., while <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery()</a> would return <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9edd9cef666ce620352e619a36b6c3f34" shape="rect">CUDA_ERROR_NOT_READY</a>). In this case, the call does not block on completion of the event, and any associated resources will automatically be released
                                 asynchronously at completion.
                              </p>
                              <p class="p"></p>
                              <p class="p"></p>
                              <p class="p">
                                 <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
                                 </div>
                              </p>
                              <p class="p"></p>
                              <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
                              <p class="p see_subsection"><a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g450687e75f3ff992fe01662a43d9d3db" title="Creates an event." shape="rect">cuEventCreate</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" title="Waits for an event to complete." shape="rect">cuEventSynchronize</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1gdfb1178807353bbcaa9e245da497cf97" title="Computes the elapsed time between two events." shape="rect">cuEventElapsedTime</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__EVENT.html#group__CUDART__EVENT_1g2cb6baa0830a1cd0bd957bfd8705045b" target="_blank" shape="rect">cudaEventDestroy</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__EVENT_1gdfb1178807353bbcaa9e245da497cf97" id="group__CUDA__EVENT_1gdfb1178807353bbcaa9e245da497cf97" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuEventElapsedTime (  float*<span>&nbsp;</span><span class="keyword keyword apiItemName">pMilliseconds</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hStart</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEnd</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Computes the elapsed time between two events. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">pMilliseconds</span></tt></dt>
                                 <dd>- Time between <tt class="ph tt code">hStart</tt> and <tt class="ph tt code">hEnd</tt> in ms 
                                 </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">hStart</span></tt></dt>
                                 <dd>- Starting event </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">hEnd</span></tt></dt>
                                 <dd>- Ending event</dd>
                              </dl>
                           </div>
                           <div class="section">
                              <h6 class="return_header">Returns</h6>
                              <p class="return"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9acf52f132faf29b473cdda6061f0f44a" shape="rect">CUDA_ERROR_DEINITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e98feb999f0af99b4a25ab26b3866f4df8" shape="rect">CUDA_ERROR_NOT_INITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a484e9af32c1e9893ff21f0e0191a12d" shape="rect">CUDA_ERROR_INVALID_CONTEXT</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e90fd2e63260c6317ba943af0f7e4b8d21" shape="rect">CUDA_ERROR_INVALID_HANDLE</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9edd9cef666ce620352e619a36b6c3f34" shape="rect">CUDA_ERROR_NOT_READY</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Computes the elapsed time between two events (in milliseconds with a resolution of around 0.5 microseconds).</p>
                              <p class="p">If either event was last recorded in a non-NULL stream, the resulting time may be greater than expected (even if both used
                                 the same stream handle). This happens because the <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord()</a> operation takes place asynchronously and there is no guarantee that the measured latency is actually just between the two
                                 events. Any number of other different stream operations could execute in between the two measured events, thus altering the
                                 timing in a significant way.
                              </p>
                              <p class="p">If <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord()</a> has not been called on either event then <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e90fd2e63260c6317ba943af0f7e4b8d21" shape="rect">CUDA_ERROR_INVALID_HANDLE</a> is returned. If <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord()</a> has been called on both events but one or both of them has not yet been completed (that is, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery()</a> would return <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9edd9cef666ce620352e619a36b6c3f34" shape="rect">CUDA_ERROR_NOT_READY</a> on at least one of the events), <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9edd9cef666ce620352e619a36b6c3f34" shape="rect">CUDA_ERROR_NOT_READY</a> is returned. If either event was created with the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f629daa5463f64794c10b78c603d23c0bff2" shape="rect">CU_EVENT_DISABLE_TIMING</a> flag, then this function will return <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e90fd2e63260c6317ba943af0f7e4b8d21" shape="rect">CUDA_ERROR_INVALID_HANDLE</a>.
                              </p>
                              <p class="p"></p>
                              <p class="p"></p>
                              <p class="p">
                                 <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
                                 </div>
                              </p>
                              <p class="p"></p>
                              <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
                              <p class="p see_subsection"><a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g450687e75f3ff992fe01662a43d9d3db" title="Creates an event." shape="rect">cuEventCreate</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" title="Waits for an event to complete." shape="rect">cuEventSynchronize</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g593ec73a8ec5a5fc031311d3e4dca1ef" title="Destroys an event." shape="rect">cuEventDestroy</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__EVENT.html#group__CUDART__EVENT_1g40159125411db92c835edb46a0989cd6" target="_blank" shape="rect">cudaEventElapsedTime</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" id="group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuEventQuery (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEvent</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Queries an event's status. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">hEvent</span></tt></dt>
                                 <dd>- Event to query</dd>
                              </dl>
                           </div>
                           <div class="section">
                              <h6 class="return_header">Returns</h6>
                              <p class="return"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9acf52f132faf29b473cdda6061f0f44a" shape="rect">CUDA_ERROR_DEINITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e98feb999f0af99b4a25ab26b3866f4df8" shape="rect">CUDA_ERROR_NOT_INITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e90fd2e63260c6317ba943af0f7e4b8d21" shape="rect">CUDA_ERROR_INVALID_HANDLE</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9edd9cef666ce620352e619a36b6c3f34" shape="rect">CUDA_ERROR_NOT_READY</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Queries the status of all work currently captured by <tt class="ph tt code">hEvent</tt>. See <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord()</a> for details on what is captured by an event.
                              </p>
                              <p class="p">Returns <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a> if all captured work has been completed, or <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9edd9cef666ce620352e619a36b6c3f34" shape="rect">CUDA_ERROR_NOT_READY</a> if any captured work is incomplete.
                              </p>
                              <p class="p">For the purposes of Unified Memory, a return value of <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a> is equivalent to having called <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" title="Waits for an event to complete." shape="rect">cuEventSynchronize()</a>.
                              </p>
                              <p class="p"></p>
                              <p class="p"></p>
                              <p class="p">
                                 <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
                                 </div>
                              </p>
                              <p class="p"></p>
                              <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
                              <p class="p see_subsection"><a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g450687e75f3ff992fe01662a43d9d3db" title="Creates an event." shape="rect">cuEventCreate</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" title="Waits for an event to complete." shape="rect">cuEventSynchronize</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g593ec73a8ec5a5fc031311d3e4dca1ef" title="Destroys an event." shape="rect">cuEventDestroy</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1gdfb1178807353bbcaa9e245da497cf97" title="Computes the elapsed time between two events." shape="rect">cuEventElapsedTime</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__EVENT.html#group__CUDART__EVENT_1g2bf738909b4a059023537eaa29d8a5b7" target="_blank" shape="rect">cudaEventQuery</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" id="group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuEventRecord (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEvent</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gb946c7f02e09efd788a204718015d88a" title="" shape="rect">CUstream</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hStream</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Records an event. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">hEvent</span></tt></dt>
                                 <dd>- Event to record </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">hStream</span></tt></dt>
                                 <dd>- Stream to record event for</dd>
                              </dl>
                           </div>
                           <div class="section">
                              <h6 class="return_header">Returns</h6>
                              <p class="return"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9acf52f132faf29b473cdda6061f0f44a" shape="rect">CUDA_ERROR_DEINITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e98feb999f0af99b4a25ab26b3866f4df8" shape="rect">CUDA_ERROR_NOT_INITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a484e9af32c1e9893ff21f0e0191a12d" shape="rect">CUDA_ERROR_INVALID_CONTEXT</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e90fd2e63260c6317ba943af0f7e4b8d21" shape="rect">CUDA_ERROR_INVALID_HANDLE</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Captures in <tt class="ph tt code">hEvent</tt> the contents of <tt class="ph tt code">hStream</tt> at the time of this call. <tt class="ph tt code">hEvent</tt> and <tt class="ph tt code">hStream</tt> must be from the same context. Calls such as <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery()</a> or <a class="xref" href="group__CUDA__STREAM.html#group__CUDA__STREAM_1g6a898b652dfc6aa1d5c8d97062618b2f" title="Make a compute stream wait on an event." shape="rect">cuStreamWaitEvent()</a> will then examine or wait for completion of the work that was captured. Uses of <tt class="ph tt code">hStream</tt> after this call do not modify <tt class="ph tt code">hEvent</tt>. See note on default stream behavior for what is captured in the default case.
                              </p>
                              <p class="p"><a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord()</a> can be called multiple times on the same event and will overwrite the previously captured state. Other APIs such as <a class="xref" href="group__CUDA__STREAM.html#group__CUDA__STREAM_1g6a898b652dfc6aa1d5c8d97062618b2f" title="Make a compute stream wait on an event." shape="rect">cuStreamWaitEvent()</a> use the most recently captured state at the time of the API call, and are not affected by later calls to <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord()</a>. Before the first call to <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord()</a>, an event represents an empty set of work, so for example <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery()</a> would return <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a>.
                              </p>
                              <p class="p"></p>
                              <p class="p"></p>
                              <p class="p">
                                 <div class="note note"><span class="notetitle">Note:</span><ul class="ul">
                                       <li class="li">
                                          <p class="p">This function uses standard  <a class="xref xmlonly" href="stream-sync-behavior.html#stream-sync-behavior__default-stream" shape="rect">default stream</a> semantics. 
                                          </p>
                                       </li>
                                       <li class="li">
                                          <p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
                                       </li>
                                    </ul>
                                 </div>
                              </p>
                              <p class="p"></p>
                              <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
                              <p class="p see_subsection"><a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g450687e75f3ff992fe01662a43d9d3db" title="Creates an event." shape="rect">cuEventCreate</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" title="Waits for an event to complete." shape="rect">cuEventSynchronize</a>, <a class="xref" href="group__CUDA__STREAM.html#group__CUDA__STREAM_1g6a898b652dfc6aa1d5c8d97062618b2f" title="Make a compute stream wait on an event." shape="rect">cuStreamWaitEvent</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g593ec73a8ec5a5fc031311d3e4dca1ef" title="Destroys an event." shape="rect">cuEventDestroy</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1gdfb1178807353bbcaa9e245da497cf97" title="Computes the elapsed time between two events." shape="rect">cuEventElapsedTime</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__EVENT.html#group__CUDART__EVENT_1gf4fcb74343aa689f4159791967868446" target="_blank" shape="rect">cudaEventRecord</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" id="group__CUDA__EVENT_1g9e520d34e51af7f5375610bca4add99c" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuEventSynchronize (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g6d740185cf0953636d4ae37f68d7559b" title="" shape="rect">CUevent</a><span>&nbsp;</span><span class="keyword keyword apiItemName">hEvent</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Waits for an event to complete. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">hEvent</span></tt></dt>
                                 <dd>- Event to wait for</dd>
                              </dl>
                           </div>
                           <div class="section">
                              <h6 class="return_header">Returns</h6>
                              <p class="return"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a0eed720f8a87cd1c5fd1c453bc7a03d" shape="rect">CUDA_SUCCESS</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9acf52f132faf29b473cdda6061f0f44a" shape="rect">CUDA_ERROR_DEINITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e98feb999f0af99b4a25ab26b3866f4df8" shape="rect">CUDA_ERROR_NOT_INITIALIZED</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a484e9af32c1e9893ff21f0e0191a12d" shape="rect">CUDA_ERROR_INVALID_CONTEXT</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e90fd2e63260c6317ba943af0f7e4b8d21" shape="rect">CUDA_ERROR_INVALID_HANDLE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Waits until the completion of all work currently captured in <tt class="ph tt code">hEvent</tt>. See <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord()</a> for details on what is captured by an event.
                              </p>
                              <p class="p">Waiting for an event that was created with the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f6296813b3b31fdb737133124f3c35044362" shape="rect">CU_EVENT_BLOCKING_SYNC</a> flag will cause the calling CPU thread to block until the event has been completed by the device. If the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg5ae04079c671c8e659a3a27c7b23f6296813b3b31fdb737133124f3c35044362" shape="rect">CU_EVENT_BLOCKING_SYNC</a> flag has not been set, then the CPU thread will busy-wait until the event has been completed by the device.
                              </p>
                              <p class="p"></p>
                              <p class="p"></p>
                              <p class="p">
                                 <div class="note note"><span class="notetitle">Note:</span><p class="p">Note that this function may also return error codes from previous, asynchronous launches.</p>
                                 </div>
                              </p>
                              <p class="p"></p>
                              <p class="p apiDesc_subtitle"><strong class="ph b">See also:</strong></p>
                              <p class="p see_subsection"><a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g450687e75f3ff992fe01662a43d9d3db" title="Creates an event." shape="rect">cuEventCreate</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g95424d3be52c4eb95d83861b70fb89d1" title="Records an event." shape="rect">cuEventRecord</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g6f0704d755066b0ee705749ae911deef" title="Queries an event's status." shape="rect">cuEventQuery</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1g593ec73a8ec5a5fc031311d3e4dca1ef" title="Destroys an event." shape="rect">cuEventDestroy</a>, <a class="xref" href="group__CUDA__EVENT.html#group__CUDA__EVENT_1gdfb1178807353bbcaa9e245da497cf97" title="Computes the elapsed time between two events." shape="rect">cuEventElapsedTime</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__EVENT.html#group__CUDART__EVENT_1g949aa42b30ae9e622f6ba0787129ff22" target="_blank" shape="rect">cudaEventSynchronize</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                     </dl>
                  </div>
               </div>
               
               <hr id="contents-end"></hr>
               
            </article>
         </div>
      </div>
      <script language="JavaScript" type="text/javascript" charset="utf-8" src="../common/formatting/common.min.js"></script>
      <script language="JavaScript" type="text/javascript" charset="utf-8" src="../common/scripts/google-analytics/google-analytics-write.js"></script>
      <script language="JavaScript" type="text/javascript" charset="utf-8" src="../common/scripts/google-analytics/google-analytics-tracker.js"></script>
      <script type="text/javascript">var switchTo5x=true;</script><script type="text/javascript" src="http://w.sharethis.com/button/buttons.js"></script><script type="text/javascript">stLight.options({publisher: "998dc202-a267-4d8e-bce9-14debadb8d92", doNotHash: false, doNotCopy: false, hashAddressBar: false});</script><script type="text/javascript">_satellite.pageBottom();</script></body>
</html>