Sophie

Sophie

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

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="Unified Addressing"></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__UNIFIED"></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__MEM.html" shape="rect">&lt; Previous</a> | <a href="group__CUDA__STREAM.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__UNIFIED"><a name="group__CUDA__UNIFIED" shape="rect">
                     <!-- --></a><h2 class="topictitle2 cppModule">5.12.&nbsp;Unified Addressing</h2>
                  <div class="section">
                     <p>This section describes the unified addressing functions of the low-level CUDA driver application programming interface.</p>
                     <p class="p apiDesc_subtitle"><strong class="ph b">Overview</strong></p>
                     <p class="p">CUDA devices can share a unified address space with the host. For these devices there is no distinction between a device pointer
                        and a host pointer -- the same pointer value may be used to access memory from the host program and from a kernel running
                        on the device (with exceptions enumerated below).
                     </p>
                     <p class="p apiDesc_subtitle"><strong class="ph b">Supported Platforms</strong></p>
                     <p class="p">Whether or not a device supports unified addressing may be queried by calling <a class="xref" href="group__CUDA__DEVICE.html#group__CUDA__DEVICE_1g9c3e1414f0ad901d3278a4d6645fc266" title="Returns information about the device." shape="rect">cuDeviceGetAttribute()</a> with the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a3dc11dd6d9f149a7bae32499f2b802c0d" shape="rect">CU_DEVICE_ATTRIBUTE_UNIFIED_ADDRESSING</a>.
                     </p>
                     <p class="p">Unified addressing is automatically enabled in 64-bit processes</p>
                     <p class="p apiDesc_subtitle"><strong class="ph b">Looking Up Information from Pointer Values</strong></p>
                     <p class="p">It is possible to look up information about the memory which backs a pointer value. For instance, one may want to know if
                        a pointer points to host or device memory. As another example, in the case of device memory, one may want to know on which
                        CUDA device the memory resides. These properties may be queried using the function <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g0c28ed0aff848042bc0533110e45820c" title="Returns information about a pointer." shape="rect">cuPointerGetAttribute()</a></p>
                     <p class="p">Since pointers are unique, it is not necessary to specify information about the pointers specified to the various copy functions
                        in the CUDA API. The function <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g8d0ff510f26d4b87bd3a51e731e7f698" title="Copies memory." shape="rect">cuMemcpy()</a> may be used to perform a copy between two pointers, ignoring whether they point to host or device memory (making <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g4d32266788c440b0220b1a9ba5795169" title="Copies memory from Host to Device." shape="rect">cuMemcpyHtoD()</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g1725774abf8b51b91945f3336b778c8b" title="Copies memory from Device to Device." shape="rect">cuMemcpyDtoD()</a>, and <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g3480368ee0208a98f75019c9a8450893" title="Copies memory from Device to Host." shape="rect">cuMemcpyDtoH()</a> unnecessary for devices supporting unified addressing). For multidimensional copies, the memory type <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg8a114cc994ad2e865c44ef3838eaec727a47ca2de6db5cf82084ad80ce66aa71" shape="rect">CU_MEMORYTYPE_UNIFIED</a> may be used to specify that the CUDA driver should infer the location of the pointer from its value.
                     </p>
                     <p class="p apiDesc_subtitle"><strong class="ph b">Automatic Mapping of Host Allocated Host Memory</strong></p>
                     <p class="p">All host memory allocated in all contexts using <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gdd8311286d2c2691605362c689bc64e0" title="Allocates page-locked host memory." shape="rect">cuMemAllocHost()</a> and <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g572ca4011bfcb25034888a14d4e035b9" title="Allocates page-locked host memory." shape="rect">cuMemHostAlloc()</a> is always directly accessible from all contexts on all devices that support unified addressing. This is the case regardless
                        of whether or not the flags <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g50f4528d46bda58b592551654a7ee0ff" shape="rect">CU_MEMHOSTALLOC_PORTABLE</a> and <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g054589ee2a0f188e664d93965d81113d" shape="rect">CU_MEMHOSTALLOC_DEVICEMAP</a> are specified.
                     </p>
                     <p class="p">The pointer value through which allocated host memory may be accessed in kernels on all devices that support unified addressing
                        is the same as the pointer value through which that memory is accessed on the host, so it is not necessary to call <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g57a39e5cba26af4d06be67fc77cc62f0" title="Passes back device pointer of mapped pinned memory." shape="rect">cuMemHostGetDevicePointer()</a> to get the device pointer for these allocations.
                     </p>
                     <p class="p">Note that this is not the case for memory allocated using the flag <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g7361580951deecace15352c97a210038" shape="rect">CU_MEMHOSTALLOC_WRITECOMBINED</a>, as discussed below.
                     </p>
                     <p class="p apiDesc_subtitle"><strong class="ph b">Automatic Registration of Peer Memory</strong></p>
                     <p class="p">Upon enabling direct access from a context that supports unified addressing to another peer context that supports unified
                        addressing using <a class="xref" href="group__CUDA__PEER__ACCESS.html#group__CUDA__PEER__ACCESS_1g0889ec6728e61c05ed359551d67b3f5a" title="Enables direct access to memory allocations in a peer context." shape="rect">cuCtxEnablePeerAccess()</a> all memory allocated in the peer context using <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb82d2a09844a58dd9e744dc31e8aa467" title="Allocates device memory." shape="rect">cuMemAlloc()</a> and <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gcbe9b033f6c4de80f63cc6e58ed9a45a" title="Allocates pitched device memory." shape="rect">cuMemAllocPitch()</a> will immediately be accessible by the current context. The device pointer value through which any peer memory may be accessed
                        in the current context is the same pointer value through which that memory may be accessed in the peer context.
                     </p>
                     <p class="p apiDesc_subtitle"><strong class="ph b">Exceptions, Disjoint Addressing</strong></p>
                     <p class="p">Not all memory may be accessed on devices through the same pointer value through which they are accessed on the host. These
                        exceptions are host memory registered using <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gf0a9fe11544326dabd743b7aa6b54223" title="Registers an existing host memory range for use by CUDA." shape="rect">cuMemHostRegister()</a> and host memory allocated using the flag <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g7361580951deecace15352c97a210038" shape="rect">CU_MEMHOSTALLOC_WRITECOMBINED</a>. For these exceptions, there exists a distinct host and device address for the memory. The device address is guaranteed to
                        not overlap any valid host pointer range and is guaranteed to have the same value across all contexts that support unified
                        addressing.
                     </p>
                     <p class="p">This device address may be queried using <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g57a39e5cba26af4d06be67fc77cc62f0" title="Passes back device pointer of mapped pinned memory." shape="rect">cuMemHostGetDevicePointer()</a> when a context using unified addressing is current. Either the host or the unified device pointer value may be used to refer
                        to this memory through <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g8d0ff510f26d4b87bd3a51e731e7f698" title="Copies memory." shape="rect">cuMemcpy()</a> and similar functions using the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg8a114cc994ad2e865c44ef3838eaec727a47ca2de6db5cf82084ad80ce66aa71" shape="rect">CU_MEMORYTYPE_UNIFIED</a> memory type. 
                     </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__UNIFIED_1g27608c857a9254789c13f3e3b72029e2" shape="rect">cuMemAdvise</a> (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">devPtr</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">count</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gcfe2ed2d4567745dd4ad41034136fff3" title="" shape="rect">CUmem_advise</a><span>&nbsp;</span><span class="keyword keyword apiItemName">advice</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gcd81b70eb9968392bb5cdf582af8eab4" title="" shape="rect">CUdevice</a><span>&nbsp;</span><span class="keyword keyword apiItemName">device</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Advise about the usage of a given memory range. </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__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" shape="rect">cuMemPrefetchAsync</a> (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">devPtr</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">count</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gcd81b70eb9968392bb5cdf582af8eab4" title="" shape="rect">CUdevice</a><span>&nbsp;</span><span class="keyword keyword apiItemName">dstDevice</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">Prefetches memory to the specified destination device. </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__UNIFIED_1g1c92408a7d0d8875e19b1a58af56f67d" shape="rect">cuMemRangeGetAttribute</a> (  void*<span>&nbsp;</span><span class="keyword keyword apiItemName">data</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">dataSize</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g3754eb90f64ed3c19b4e550d21d124fc" title="" shape="rect">CUmem_range_attribute</a><span>&nbsp;</span><span class="keyword keyword apiItemName">attribute</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">devPtr</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">count</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Query an attribute of a given memory range. </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__UNIFIED_1gc7ce142e60f8613cfb7d722b87dc9d12" shape="rect">cuMemRangeGetAttributes</a> (  void**<span>&nbsp;</span><span class="keyword keyword apiItemName">data</span>, size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">dataSizes</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g3754eb90f64ed3c19b4e550d21d124fc" title="" shape="rect">CUmem_range_attribute</a>*<span>&nbsp;</span><span class="keyword keyword apiItemName">attributes</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">numAttributes</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">devPtr</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">count</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Query attributes of a given memory range. </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__UNIFIED_1g0c28ed0aff848042bc0533110e45820c" shape="rect">cuPointerGetAttribute</a> (  void*<span>&nbsp;</span><span class="keyword keyword apiItemName">data</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc2cce590e35080745e72633dfc6e0b60" title="" shape="rect">CUpointer_attribute</a><span>&nbsp;</span><span class="keyword keyword apiItemName">attribute</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">ptr</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Returns information about a pointer. </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__UNIFIED_1gf65e9ea532e311dd049166e4894955ad" shape="rect">cuPointerGetAttributes</a> (  unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">numAttributes</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc2cce590e35080745e72633dfc6e0b60" title="" shape="rect">CUpointer_attribute</a>*<span>&nbsp;</span><span class="keyword keyword apiItemName">attributes</span>, void**<span>&nbsp;</span><span class="keyword keyword apiItemName">data</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">ptr</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Returns information about a pointer. </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__UNIFIED_1g89f7ad29a657e574fdea2624b74d138e" shape="rect">cuPointerSetAttribute</a> (  const void*<span>&nbsp;</span><span class="keyword keyword apiItemName">value</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc2cce590e35080745e72633dfc6e0b60" title="" shape="rect">CUpointer_attribute</a><span>&nbsp;</span><span class="keyword keyword apiItemName">attribute</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">ptr</span> ) </span></dt>
                     <dd class="shortdesc"><span></span><span class="desc">Set attributes on a previously allocated memory region. </span></dd>
                  </dl>
                  <div class="description">
                     <h3 class="sectiontitle">Functions</h3>
                     <dl class="description">
                        <dt class="description"><a name="group__CUDA__UNIFIED_1g27608c857a9254789c13f3e3b72029e2" id="group__CUDA__UNIFIED_1g27608c857a9254789c13f3e3b72029e2" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuMemAdvise (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">devPtr</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">count</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gcfe2ed2d4567745dd4ad41034136fff3" title="" shape="rect">CUmem_advise</a><span>&nbsp;</span><span class="keyword keyword apiItemName">advice</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gcd81b70eb9968392bb5cdf582af8eab4" title="" shape="rect">CUdevice</a><span>&nbsp;</span><span class="keyword keyword apiItemName">device</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Advise about the usage of a given memory range. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">devPtr</span></tt></dt>
                                 <dd>- Pointer to memory to set the advice for </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">count</span></tt></dt>
                                 <dd>- Size in bytes of the memory range </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">advice</span></tt></dt>
                                 <dd>- Advice to be applied for the specified memory range </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">device</span></tt></dt>
                                 <dd>- Device to apply the advice 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_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e96f047e7215788ca96c81af92a04bfb6c" shape="rect">CUDA_ERROR_INVALID_DEVICE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Advise the Unified Memory subsystem about the usage pattern for the memory range starting at <tt class="ph tt code">devPtr</tt> with a size of <tt class="ph tt code">count</tt> bytes. The start address and end address of the memory range will be rounded down and rounded up respectively to be aligned
                                 to CPU page size before the advice is applied. The memory range must refer to managed memory allocated via <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb347ded34dc326af404aa02af5388a32" title="Allocates memory that will be automatically managed by the Unified Memory system." shape="rect">cuMemAllocManaged</a> or declared via __managed__ variables. The memory range could also refer to system-allocated pageable memory provided it
                                 represents a valid, host-accessible region of memory and all additional constraints imposed by <tt class="ph tt code">advice</tt> as outlined below are also satisfied. Specifying an invalid system-allocated pageable memory range results in an error being
                                 returned.
                              </p>
                              <p class="p">The <tt class="ph tt code">advice</tt> parameter can take the following values:
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff35a99fb44378c84c56668550b94157fc0" shape="rect">CU_MEM_ADVISE_SET_READ_MOSTLY</a>: This implies that the data is mostly going to be read from and only occasionally written to. Any read accesses from any
                                          processor to this region will create a read-only copy of at least the accessed pages in that processor's memory. Additionally,
                                          if <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" title="Prefetches memory to the specified destination device." shape="rect">cuMemPrefetchAsync</a> is called on this region, it will create a read-only copy of the data on the destination processor. If any processor writes
                                          to this region, all copies of the corresponding page will be invalidated except for the one where the write occurred. The
                                          <tt class="ph tt code">device</tt> argument is ignored for this advice. Note that for a page to be read-duplicated, the accessing processor must either be the
                                          CPU or a GPU that has a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a333110e44c9cb6ead02f03ff6f6fd495e" shape="rect">CU_DEVICE_ATTRIBUTE_CONCURRENT_MANAGED_ACCESS</a>. Also, if a context is created on a device that does not have the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a333110e44c9cb6ead02f03ff6f6fd495e" shape="rect">CU_DEVICE_ATTRIBUTE_CONCURRENT_MANAGED_ACCESS</a> set, then read-duplication will not occur until all such contexts are destroyed. If the memory region refers to valid system-allocated
                                          pageable memory, then the accessing device must have a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a35fdcdbe1dfc3ad5ec428c279e0efb9cd" shape="rect">CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS</a> for a read-only copy to be created on that device. Note however that if the accessing device also has a non-zero value for
                                          the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a352c58d6fd1d3a72673cce199ab30cd40" shape="rect">CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS_USES_HOST_PAGE_TABLES</a>, then setting this advice will not create a read-only copy when that device accesses this memory region.
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff383a9e9744ef151f7b25b5c902ba6baca" shape="rect">CU_MEM_ADVISE_UNSET_READ_MOSTLY</a>: Undoes the effect of <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff35a99fb44378c84c56668550b94157fc0" shape="rect">CU_MEM_ADVISE_SET_READ_MOSTLY</a> and also prevents the Unified Memory driver from attempting heuristic read-duplication on the memory range. Any read-duplicated
                                          copies of the data will be collapsed into a single copy. The location for the collapsed copy will be the preferred location
                                          if the page has a preferred location and one of the read-duplicated copies was resident at that location. Otherwise, the location
                                          chosen is arbitrary.
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3ddee285dc5e0e7d26469009ffd583cea" shape="rect">CU_MEM_ADVISE_SET_PREFERRED_LOCATION</a>: This advice sets the preferred location for the data to be the memory belonging to <tt class="ph tt code">device</tt>. Passing in CU_DEVICE_CPU for <tt class="ph tt code">device</tt> sets the preferred location as host memory. If <tt class="ph tt code">device</tt> is a GPU, then it must have a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a333110e44c9cb6ead02f03ff6f6fd495e" shape="rect">CU_DEVICE_ATTRIBUTE_CONCURRENT_MANAGED_ACCESS</a>. Setting the preferred location does not cause data to migrate to that location immediately. Instead, it guides the migration
                                          policy when a fault occurs on that memory region. If the data is already in its preferred location and the faulting processor
                                          can establish a mapping without requiring the data to be migrated, then data migration will be avoided. On the other hand,
                                          if the data is not in its preferred location or if a direct mapping cannot be established, then it will be migrated to the
                                          processor accessing it. It is important to note that setting the preferred location does not prevent data prefetching done
                                          using <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" title="Prefetches memory to the specified destination device." shape="rect">cuMemPrefetchAsync</a>. Having a preferred location can override the page thrash detection and resolution logic in the Unified Memory driver. Normally,
                                          if a page is detected to be constantly thrashing between for example host and device memory, the page may eventually be pinned
                                          to host memory by the Unified Memory driver. But if the preferred location is set as device memory, then the page will continue
                                          to thrash indefinitely. If <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff35a99fb44378c84c56668550b94157fc0" shape="rect">CU_MEM_ADVISE_SET_READ_MOSTLY</a> is also set on this memory region or any subset of it, then the policies associated with that advice will override the policies
                                          of this advice, unless read accesses from <tt class="ph tt code">device</tt> will not result in a read-only copy being created on that device as outlined in description for the advice <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff35a99fb44378c84c56668550b94157fc0" shape="rect">CU_MEM_ADVISE_SET_READ_MOSTLY</a>. If the memory region refers to valid system-allocated pageable memory, then <tt class="ph tt code">device</tt> must have a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a35fdcdbe1dfc3ad5ec428c279e0efb9cd" shape="rect">CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS</a>. Additionally, if <tt class="ph tt code">device</tt> has a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a352c58d6fd1d3a72673cce199ab30cd40" shape="rect">CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS_USES_HOST_PAGE_TABLES</a>, then this call has no effect. Note however that this behavior may change in the future.
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff31d0d3a6b5273abd3f758d55a020bb6ca" shape="rect">CU_MEM_ADVISE_UNSET_PREFERRED_LOCATION</a>: Undoes the effect of <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3ddee285dc5e0e7d26469009ffd583cea" shape="rect">CU_MEM_ADVISE_SET_PREFERRED_LOCATION</a> and changes the preferred location to none.
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3a44e5c0ad0a77d05332739848e181a2d" shape="rect">CU_MEM_ADVISE_SET_ACCESSED_BY</a>: This advice implies that the data will be accessed by <tt class="ph tt code">device</tt>. Passing in <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g2a24bee5711059aaee8329bdc8799790" shape="rect">CU_DEVICE_CPU</a> for <tt class="ph tt code">device</tt> will set the advice for the CPU. If <tt class="ph tt code">device</tt> is a GPU, then the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a333110e44c9cb6ead02f03ff6f6fd495e" shape="rect">CU_DEVICE_ATTRIBUTE_CONCURRENT_MANAGED_ACCESS</a> must be non-zero. This advice does not cause data migration and has no impact on the location of the data per se. Instead,
                                          it causes the data to always be mapped in the specified processor's page tables, as long as the location of the data permits
                                          a mapping to be established. If the data gets migrated for any reason, the mappings are updated accordingly. This advice is
                                          recommended in scenarios where data locality is not important, but avoiding faults is. Consider for example a system containing
                                          multiple GPUs with peer-to-peer access enabled, where the data located on one GPU is occasionally accessed by peer GPUs. In
                                          such scenarios, migrating data over to the other GPUs is not as important because the accesses are infrequent and the overhead
                                          of migration may be too high. But preventing faults can still help improve performance, and so having a mapping set up in
                                          advance is useful. Note that on CPU access of this data, the data may be migrated to host memory because the CPU typically
                                          cannot access device memory directly. Any GPU that had the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3a44e5c0ad0a77d05332739848e181a2d" shape="rect">CU_MEM_ADVISE_SET_ACCESSED_BY</a> flag set for this data will now have its mapping updated to point to the page in host memory. If <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff35a99fb44378c84c56668550b94157fc0" shape="rect">CU_MEM_ADVISE_SET_READ_MOSTLY</a> is also set on this memory region or any subset of it, then the policies associated with that advice will override the policies
                                          of this advice. Additionally, if the preferred location of this memory region or any subset of it is also <tt class="ph tt code">device</tt>, then the policies associated with <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3ddee285dc5e0e7d26469009ffd583cea" shape="rect">CU_MEM_ADVISE_SET_PREFERRED_LOCATION</a> will override the policies of this advice. If the memory region refers to valid system-allocated pageable memory, then <tt class="ph tt code">device</tt> must have a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a35fdcdbe1dfc3ad5ec428c279e0efb9cd" shape="rect">CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS</a>. Additionally, if <tt class="ph tt code">device</tt> has a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a352c58d6fd1d3a72673cce199ab30cd40" shape="rect">CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS_USES_HOST_PAGE_TABLES</a>, then this call has no effect.
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3f8118635c5f39d76432654ec13a726a5" shape="rect">CU_MEM_ADVISE_UNSET_ACCESSED_BY</a>: Undoes the effect of <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3a44e5c0ad0a77d05332739848e181a2d" shape="rect">CU_MEM_ADVISE_SET_ACCESSED_BY</a>. Any mappings to the data from <tt class="ph tt code">device</tt> may be removed at any time causing accesses to result in non-fatal page faults. If the memory region refers to valid system-allocated
                                          pageable memory, then <tt class="ph tt code">device</tt> must have a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a35fdcdbe1dfc3ad5ec428c279e0efb9cd" shape="rect">CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS</a>. Additionally, if <tt class="ph tt code">device</tt> has a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a352c58d6fd1d3a72673cce199ab30cd40" shape="rect">CU_DEVICE_ATTRIBUTE_PAGEABLE_MEMORY_ACCESS_USES_HOST_PAGE_TABLES</a>, then this call has no effect.
                                       </p>
                                    </li>
                                 </ul>
                              </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">Note that this function may also return error codes from previous, asynchronous launches. </p>
                                       </li>
                                       <li class="li">
                                          <p class="p">This function exhibits  <a class="xref xmlonly" href="api-sync-behavior.html#api-sync-behavior__memcpy-async" shape="rect">asynchronous</a> behavior for most use cases. 
                                          </p>
                                       </li>
                                       <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>
                                    </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__MEM.html#group__CUDA__MEM_1g8d0ff510f26d4b87bd3a51e731e7f698" title="Copies memory." shape="rect">cuMemcpy</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1ge1f5c7771544fee150ada8853c7cbf4a" title="Copies device memory between two contexts." shape="rect">cuMemcpyPeer</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g5f26aaf5582ade791e5688727a178d78" title="Copies memory asynchronously." shape="rect">cuMemcpyAsync</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gc4e4bfd9f627d3aa3695979e058f1bb8" title="Copies memory between contexts asynchronously." shape="rect">cuMemcpy3DPeerAsync</a>, <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" title="Prefetches memory to the specified destination device." shape="rect">cuMemPrefetchAsync</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__MEMORY.html#group__CUDART__MEMORY_1ge37112fc1ac88d0f6bab7a945e48760a" target="_blank" shape="rect">cudaMemAdvise</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" id="group__CUDA__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuMemPrefetchAsync (  <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">devPtr</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">count</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gcd81b70eb9968392bb5cdf582af8eab4" title="" shape="rect">CUdevice</a><span>&nbsp;</span><span class="keyword keyword apiItemName">dstDevice</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">Prefetches memory to the specified destination device. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">devPtr</span></tt></dt>
                                 <dd>- Pointer to be prefetched </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">count</span></tt></dt>
                                 <dd>- Size in bytes </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">dstDevice</span></tt></dt>
                                 <dd>- Destination device to prefetch to </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">hStream</span></tt></dt>
                                 <dd>- Stream to enqueue prefetch operation</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_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e96f047e7215788ca96c81af92a04bfb6c" shape="rect">CUDA_ERROR_INVALID_DEVICE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Prefetches memory to the specified destination device. <tt class="ph tt code">devPtr</tt> is the base device pointer of the memory to be prefetched and <tt class="ph tt code">dstDevice</tt> is the destination device. <tt class="ph tt code">count</tt> specifies the number of bytes to copy. <tt class="ph tt code">hStream</tt> is the stream in which the operation is enqueued. The memory range must refer to managed memory allocated via <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb347ded34dc326af404aa02af5388a32" title="Allocates memory that will be automatically managed by the Unified Memory system." shape="rect">cuMemAllocManaged</a> or declared via __managed__ variables.
                              </p>
                              <p class="p">Passing in CU_DEVICE_CPU for <tt class="ph tt code">dstDevice</tt> will prefetch the data to host memory. If <tt class="ph tt code">dstDevice</tt> is a GPU, then the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a333110e44c9cb6ead02f03ff6f6fd495e" shape="rect">CU_DEVICE_ATTRIBUTE_CONCURRENT_MANAGED_ACCESS</a> must be non-zero. Additionally, <tt class="ph tt code">hStream</tt> must be associated with a device that has a non-zero value for the device attribute <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gge12b8a782bebe21b1ac0091bf9f4e2a333110e44c9cb6ead02f03ff6f6fd495e" shape="rect">CU_DEVICE_ATTRIBUTE_CONCURRENT_MANAGED_ACCESS</a>.
                              </p>
                              <p class="p">The start address and end address of the memory range will be rounded down and rounded up respectively to be aligned to CPU
                                 page size before the prefetch operation is enqueued in the stream.
                              </p>
                              <p class="p">If no physical memory has been allocated for this region, then this memory region will be populated and mapped on the destination
                                 device. If there's insufficient memory to prefetch the desired region, the Unified Memory driver may evict pages from other
                                 <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb347ded34dc326af404aa02af5388a32" title="Allocates memory that will be automatically managed by the Unified Memory system." shape="rect">cuMemAllocManaged</a> allocations to host memory in order to make room. Device memory allocated using <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb82d2a09844a58dd9e744dc31e8aa467" title="Allocates device memory." shape="rect">cuMemAlloc</a> or <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g4192ff387a81c3bd5ed8c391ed62ca24" title="Creates a 1D or 2D CUDA array." shape="rect">cuArrayCreate</a> will not be evicted.
                              </p>
                              <p class="p">By default, any mappings to the previous location of the migrated pages are removed and mappings for the new location are
                                 only setup on <tt class="ph tt code">dstDevice</tt>. The exact behavior however also depends on the settings applied to this memory range via <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g27608c857a9254789c13f3e3b72029e2" title="Advise about the usage of a given memory range." shape="rect">cuMemAdvise</a> as described below:
                              </p>
                              <p class="p">If <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff35a99fb44378c84c56668550b94157fc0" shape="rect">CU_MEM_ADVISE_SET_READ_MOSTLY</a> was set on any subset of this memory range, then that subset will create a read-only copy of the pages on <tt class="ph tt code">dstDevice</tt>.
                              </p>
                              <p class="p">If <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3ddee285dc5e0e7d26469009ffd583cea" shape="rect">CU_MEM_ADVISE_SET_PREFERRED_LOCATION</a> was called on any subset of this memory range, then the pages will be migrated to <tt class="ph tt code">dstDevice</tt> even if <tt class="ph tt code">dstDevice</tt> is not the preferred location of any pages in the memory range.
                              </p>
                              <p class="p">If <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3a44e5c0ad0a77d05332739848e181a2d" shape="rect">CU_MEM_ADVISE_SET_ACCESSED_BY</a> was called on any subset of this memory range, then mappings to those pages from all the appropriate processors are updated
                                 to refer to the new location if establishing such a mapping is possible. Otherwise, those mappings are cleared.
                              </p>
                              <p class="p">Note that this API is not required for functionality and only serves to improve performance by allowing the application to
                                 migrate data to a suitable location before it is accessed. Memory accesses to this range are always coherent and are allowed
                                 even when the data is actively being migrated.
                              </p>
                              <p class="p">Note that this function is asynchronous with respect to the host and all work on other devices.</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">Note that this function may also return error codes from previous, asynchronous launches. </p>
                                       </li>
                                       <li class="li">
                                          <p class="p">This function exhibits  <a class="xref xmlonly" href="api-sync-behavior.html#api-sync-behavior__memcpy-async" shape="rect">asynchronous</a> behavior for most use cases. 
                                          </p>
                                       </li>
                                       <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>
                                    </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__MEM.html#group__CUDA__MEM_1g8d0ff510f26d4b87bd3a51e731e7f698" title="Copies memory." shape="rect">cuMemcpy</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1ge1f5c7771544fee150ada8853c7cbf4a" title="Copies device memory between two contexts." shape="rect">cuMemcpyPeer</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g5f26aaf5582ade791e5688727a178d78" title="Copies memory asynchronously." shape="rect">cuMemcpyAsync</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gc4e4bfd9f627d3aa3695979e058f1bb8" title="Copies memory between contexts asynchronously." shape="rect">cuMemcpy3DPeerAsync</a>, <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g27608c857a9254789c13f3e3b72029e2" title="Advise about the usage of a given memory range." shape="rect">cuMemAdvise</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__MEMORY.html#group__CUDART__MEMORY_1ge8dc9199943d421bc8bc7f473df12e42" target="_blank" shape="rect">cudaMemPrefetchAsync</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__UNIFIED_1g1c92408a7d0d8875e19b1a58af56f67d" id="group__CUDA__UNIFIED_1g1c92408a7d0d8875e19b1a58af56f67d" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuMemRangeGetAttribute (  void*<span>&nbsp;</span><span class="keyword keyword apiItemName">data</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">dataSize</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g3754eb90f64ed3c19b4e550d21d124fc" title="" shape="rect">CUmem_range_attribute</a><span>&nbsp;</span><span class="keyword keyword apiItemName">attribute</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">devPtr</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">count</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Query an attribute of a given memory range. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">data</span></tt></dt>
                                 <dd>- A pointers to a memory location where the result of each attribute query will be written to. </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">dataSize</span></tt></dt>
                                 <dd>- Array containing the size of data </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">attribute</span></tt></dt>
                                 <dd>- The attribute to query </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">devPtr</span></tt></dt>
                                 <dd>- Start of the range to query </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">count</span></tt></dt>
                                 <dd>- Size of the range 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_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a>, <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e96f047e7215788ca96c81af92a04bfb6c" shape="rect">CUDA_ERROR_INVALID_DEVICE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Query an attribute about the memory range starting at <tt class="ph tt code">devPtr</tt> with a size of <tt class="ph tt code">count</tt> bytes. The memory range must refer to managed memory allocated via <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb347ded34dc326af404aa02af5388a32" title="Allocates memory that will be automatically managed by the Unified Memory system." shape="rect">cuMemAllocManaged</a> or declared via __managed__ variables.
                              </p>
                              <p class="p">The <tt class="ph tt code">attribute</tt> parameter can take the following values:
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg3754eb90f64ed3c19b4e550d21d124fcb21856250c588cd795462323c71fef7b" shape="rect">CU_MEM_RANGE_ATTRIBUTE_READ_MOSTLY</a>: If this attribute is specified, <tt class="ph tt code">data</tt> will be interpreted as a 32-bit integer, and <tt class="ph tt code">dataSize</tt> must be 4. The result returned will be 1 if all pages in the given memory range have read-duplication enabled, or 0 otherwise.
                                       </p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg3754eb90f64ed3c19b4e550d21d124fcc68a2f5771f8e1b83ad29c1d65ab4875" shape="rect">CU_MEM_RANGE_ATTRIBUTE_PREFERRED_LOCATION</a>: If this attribute is specified, <tt class="ph tt code">data</tt> will be interpreted as a 32-bit integer, and <tt class="ph tt code">dataSize</tt> must be 4. The result returned will be a GPU device id if all pages in the memory range have that GPU as their preferred
                                          location, or it will be CU_DEVICE_CPU if all pages in the memory range have the CPU as their preferred location, or it will
                                          be CU_DEVICE_INVALID if either all the pages don't have the same preferred location or some of the pages don't have a preferred
                                          location at all. Note that the actual location of the pages in the memory range at the time of the query may be different
                                          from the preferred location.
                                       </p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg3754eb90f64ed3c19b4e550d21d124fc2511c59b3d309b83f410af68280891a4" shape="rect">CU_MEM_RANGE_ATTRIBUTE_ACCESSED_BY</a>: If this attribute is specified, <tt class="ph tt code">data</tt> will be interpreted as an array of 32-bit integers, and <tt class="ph tt code">dataSize</tt> must be a non-zero multiple of 4. The result returned will be a list of device ids that had <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggcfe2ed2d4567745dd4ad41034136fff3a44e5c0ad0a77d05332739848e181a2d" shape="rect">CU_MEM_ADVISE_SET_ACCESSED_BY</a> set for that entire memory range. If any device does not have that advice set for the entire memory range, that device will
                                          not be included. If <tt class="ph tt code">data</tt> is larger than the number of devices that have that advice set for that memory range, CU_DEVICE_INVALID will be returned
                                          in all the extra space provided. For ex., if <tt class="ph tt code">dataSize</tt> is 12 (i.e. <tt class="ph tt code">data</tt> has 3 elements) and only device 0 has the advice set, then the result returned will be { 0, CU_DEVICE_INVALID, CU_DEVICE_INVALID
                                          }. If <tt class="ph tt code">data</tt> is smaller than the number of devices that have that advice set, then only as many devices will be returned as can fit in
                                          the array. There is no guarantee on which specific devices will be returned, however.
                                       </p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg3754eb90f64ed3c19b4e550d21d124fc5213666bebedfcea6128fbebaa2f7ade" shape="rect">CU_MEM_RANGE_ATTRIBUTE_LAST_PREFETCH_LOCATION</a>: If this attribute is specified, <tt class="ph tt code">data</tt> will be interpreted as a 32-bit integer, and <tt class="ph tt code">dataSize</tt> must be 4. The result returned will be the last location to which all pages in the memory range were prefetched explicitly
                                          via <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" title="Prefetches memory to the specified destination device." shape="rect">cuMemPrefetchAsync</a>. This will either be a GPU id or CU_DEVICE_CPU depending on whether the last location for prefetch was a GPU or the CPU respectively.
                                          If any page in the memory range was never explicitly prefetched or if all pages were not prefetched to the same location,
                                          CU_DEVICE_INVALID will be returned. Note that this simply returns the last location that the applicaton requested to prefetch
                                          the memory range to. It gives no indication as to whether the prefetch operation to that location has completed or even begun.
                                       </p>
                                    </li>
                                 </ul>
                              </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">Note that this function may also return error codes from previous, asynchronous launches. </p>
                                       </li>
                                       <li class="li">
                                          <p class="p">This function exhibits  <a class="xref xmlonly" href="api-sync-behavior.html#api-sync-behavior__memcpy-async" shape="rect">asynchronous</a> behavior for most use cases. 
                                          </p>
                                       </li>
                                       <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>
                                    </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__UNIFIED.html#group__CUDA__UNIFIED_1gc7ce142e60f8613cfb7d722b87dc9d12" title="Query attributes of a given memory range." shape="rect">cuMemRangeGetAttributes</a>, <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" title="Prefetches memory to the specified destination device." shape="rect">cuMemPrefetchAsync</a>, <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g27608c857a9254789c13f3e3b72029e2" title="Advise about the usage of a given memory range." shape="rect">cuMemAdvise</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__MEMORY.html#group__CUDART__MEMORY_1g8048f6ea5ad77917444567656c140c5a" target="_blank" shape="rect">cudaMemRangeGetAttribute</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__UNIFIED_1gc7ce142e60f8613cfb7d722b87dc9d12" id="group__CUDA__UNIFIED_1gc7ce142e60f8613cfb7d722b87dc9d12" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuMemRangeGetAttributes (  void**<span>&nbsp;</span><span class="keyword keyword apiItemName">data</span>, size_t*<span>&nbsp;</span><span class="keyword keyword apiItemName">dataSizes</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g3754eb90f64ed3c19b4e550d21d124fc" title="" shape="rect">CUmem_range_attribute</a>*<span>&nbsp;</span><span class="keyword keyword apiItemName">attributes</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">numAttributes</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">devPtr</span>, size_t<span>&nbsp;</span><span class="keyword keyword apiItemName">count</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Query attributes of a given memory range. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">data</span></tt></dt>
                                 <dd>- A two-dimensional array containing pointers to memory locations where the result of each attribute query will be written
                                    to. 
                                 </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">dataSizes</span></tt></dt>
                                 <dd>- Array containing the sizes of each result </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">attributes</span></tt></dt>
                                 <dd>- An array of attributes to query (numAttributes and the number of attributes in this array should match) </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">numAttributes</span></tt></dt>
                                 <dd>- Number of attributes to query </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">devPtr</span></tt></dt>
                                 <dd>- Start of the range to query </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">count</span></tt></dt>
                                 <dd>- Size of the range 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_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_1ggc6c391505e117393cc2558fff6bfc2e96f047e7215788ca96c81af92a04bfb6c" shape="rect">CUDA_ERROR_INVALID_DEVICE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>Query attributes of the memory range starting at <tt class="ph tt code">devPtr</tt> with a size of <tt class="ph tt code">count</tt> bytes. The memory range must refer to managed memory allocated via <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb347ded34dc326af404aa02af5388a32" title="Allocates memory that will be automatically managed by the Unified Memory system." shape="rect">cuMemAllocManaged</a> or declared via __managed__ variables. The <tt class="ph tt code">attributes</tt> array will be interpreted to have <tt class="ph tt code">numAttributes</tt> entries. The <tt class="ph tt code">dataSizes</tt> array will also be interpreted to have <tt class="ph tt code">numAttributes</tt> entries. The results of the query will be stored in <tt class="ph tt code">data</tt>.
                              </p>
                              <p class="p">The list of supported attributes are given below. Please refer to <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g1c92408a7d0d8875e19b1a58af56f67d" title="Query an attribute of a given memory range." shape="rect">cuMemRangeGetAttribute</a> for attribute descriptions and restrictions.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg3754eb90f64ed3c19b4e550d21d124fcb21856250c588cd795462323c71fef7b" shape="rect">CU_MEM_RANGE_ATTRIBUTE_READ_MOSTLY</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg3754eb90f64ed3c19b4e550d21d124fcc68a2f5771f8e1b83ad29c1d65ab4875" shape="rect">CU_MEM_RANGE_ATTRIBUTE_PREFERRED_LOCATION</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg3754eb90f64ed3c19b4e550d21d124fc2511c59b3d309b83f410af68280891a4" shape="rect">CU_MEM_RANGE_ATTRIBUTE_ACCESSED_BY</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg3754eb90f64ed3c19b4e550d21d124fc5213666bebedfcea6128fbebaa2f7ade" shape="rect">CU_MEM_RANGE_ATTRIBUTE_LAST_PREFETCH_LOCATION</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__UNIFIED.html#group__CUDA__UNIFIED_1g1c92408a7d0d8875e19b1a58af56f67d" title="Query an attribute of a given memory range." shape="rect">cuMemRangeGetAttribute</a>, <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g27608c857a9254789c13f3e3b72029e2" title="Advise about the usage of a given memory range." shape="rect">cuMemAdvise</a><a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1gfe94f8b7fb56291ebcea44261aa4cb84" title="Prefetches memory to the specified destination device." shape="rect">cuMemPrefetchAsync</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__MEMORY.html#group__CUDART__MEMORY_1g1a9199e7709c7817d1c715cfbe174d05" target="_blank" shape="rect">cudaMemRangeGetAttributes</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__UNIFIED_1g0c28ed0aff848042bc0533110e45820c" id="group__CUDA__UNIFIED_1g0c28ed0aff848042bc0533110e45820c" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuPointerGetAttribute (  void*<span>&nbsp;</span><span class="keyword keyword apiItemName">data</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc2cce590e35080745e72633dfc6e0b60" title="" shape="rect">CUpointer_attribute</a><span>&nbsp;</span><span class="keyword keyword apiItemName">attribute</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">ptr</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Returns information about a pointer. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">data</span></tt></dt>
                                 <dd>- Returned pointer attribute value </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">attribute</span></tt></dt>
                                 <dd>- Pointer attribute to query </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">ptr</span></tt></dt>
                                 <dd>- Pointer</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_1ggc6c391505e117393cc2558fff6bfc2e96f047e7215788ca96c81af92a04bfb6c" shape="rect">CUDA_ERROR_INVALID_DEVICE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>The supported attributes are:</p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60f0470fdbd1a5ff72c341f762f49506ab" shape="rect">CU_POINTER_ATTRIBUTE_CONTEXT</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">Returns in <tt class="ph tt code">*data</tt> the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> in which <tt class="ph tt code">ptr</tt> was allocated or registered. The type of <tt class="ph tt code">data</tt> must be <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> *.
                              </p>
                              <p class="p">If <tt class="ph tt code">ptr</tt> was not allocated by, mapped by, or registered with a <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> which uses unified virtual addressing then <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a> is returned.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b600409e16293b60b383f30a9b417b2917c" shape="rect">CU_POINTER_ATTRIBUTE_MEMORY_TYPE</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">Returns in <tt class="ph tt code">*data</tt> the physical memory type of the memory that <tt class="ph tt code">ptr</tt> addresses as a <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g8a114cc994ad2e865c44ef3838eaec72" shape="rect">CUmemorytype</a> enumerated value. The type of <tt class="ph tt code">data</tt> must be unsigned int.
                              </p>
                              <p class="p">If <tt class="ph tt code">ptr</tt> addresses device memory then <tt class="ph tt code">*data</tt> is set to <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg8a114cc994ad2e865c44ef3838eaec72ec7e15ba4b111a26adb3487023707299" shape="rect">CU_MEMORYTYPE_DEVICE</a>. The particular <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gcd81b70eb9968392bb5cdf582af8eab4" shape="rect">CUdevice</a> on which the memory resides is the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gcd81b70eb9968392bb5cdf582af8eab4" shape="rect">CUdevice</a> of the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> returned by the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60f0470fdbd1a5ff72c341f762f49506ab" shape="rect">CU_POINTER_ATTRIBUTE_CONTEXT</a> attribute of <tt class="ph tt code">ptr</tt>.
                              </p>
                              <p class="p">If <tt class="ph tt code">ptr</tt> addresses host memory then <tt class="ph tt code">*data</tt> is set to <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gg8a114cc994ad2e865c44ef3838eaec727f98a88f26eec8490bfc180c5a73e101" shape="rect">CU_MEMORYTYPE_HOST</a>.
                              </p>
                              <p class="p">If <tt class="ph tt code">ptr</tt> was not allocated by, mapped by, or registered with a <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> which uses unified virtual addressing then <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a> is returned.
                              </p>
                              <p class="p">If the current <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> does not support unified virtual addressing then <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a484e9af32c1e9893ff21f0e0191a12d" shape="rect">CUDA_ERROR_INVALID_CONTEXT</a> is returned.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60b5446064bbfa484ea8d13025f1573d5d" shape="rect">CU_POINTER_ATTRIBUTE_DEVICE_POINTER</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">Returns in <tt class="ph tt code">*data</tt> the device pointer value through which <tt class="ph tt code">ptr</tt> may be accessed by kernels running in the current <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a>. The type of <tt class="ph tt code">data</tt> must be CUdeviceptr *.
                              </p>
                              <p class="p">If there exists no device pointer value through which kernels running in the current <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> may access <tt class="ph tt code">ptr</tt> then <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a> is returned.
                              </p>
                              <p class="p">If there is no current <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> then <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a484e9af32c1e9893ff21f0e0191a12d" shape="rect">CUDA_ERROR_INVALID_CONTEXT</a> is returned.
                              </p>
                              <p class="p">Except in the exceptional disjoint addressing cases discussed below, the value returned in <tt class="ph tt code">*data</tt> will equal the input value <tt class="ph tt code">ptr</tt>.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60ab17d9902b1b631982ae6a3a9a436fdc" shape="rect">CU_POINTER_ATTRIBUTE_HOST_POINTER</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">Returns in <tt class="ph tt code">*data</tt> the host pointer value through which <tt class="ph tt code">ptr</tt> may be accessed by by the host program. The type of <tt class="ph tt code">data</tt> must be void **. If there exists no host pointer value through which the host program may directly access <tt class="ph tt code">ptr</tt> then <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e990696c86fcee1f536a1ec7d25867feeb" shape="rect">CUDA_ERROR_INVALID_VALUE</a> is returned.
                              </p>
                              <p class="p">Except in the exceptional disjoint addressing cases discussed below, the value returned in <tt class="ph tt code">*data</tt> will equal the input value <tt class="ph tt code">ptr</tt>.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60995003218508cc15bfcf197aa9b30a1b" shape="rect">CU_POINTER_ATTRIBUTE_P2P_TOKENS</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">Returns in <tt class="ph tt code">*data</tt> two tokens for use with the nv-p2p.h Linux kernel interface. <tt class="ph tt code">data</tt> must be a struct of type <a class="xref" href="structCUDA__POINTER__ATTRIBUTE__P2P__TOKENS.html#structCUDA__POINTER__ATTRIBUTE__P2P__TOKENS" shape="rect">CUDA_POINTER_ATTRIBUTE_P2P_TOKENS</a>.
                              </p>
                              <p class="p"><tt class="ph tt code">ptr</tt> must be a pointer to memory obtained from :<a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb82d2a09844a58dd9e744dc31e8aa467" title="Allocates device memory." shape="rect">cuMemAlloc()</a>. Note that p2pToken and vaSpaceToken are only valid for the lifetime of the source allocation. A subsequent allocation at
                                 the same address may return completely different tokens. Querying this attribute has a side effect of setting the attribute
                                 <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60db5380c3201afdae3556cce8834504e1" shape="rect">CU_POINTER_ATTRIBUTE_SYNC_MEMOPS</a> for the region of memory that <tt class="ph tt code">ptr</tt> points to.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60db5380c3201afdae3556cce8834504e1" shape="rect">CU_POINTER_ATTRIBUTE_SYNC_MEMOPS</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">A boolean attribute which when set, ensures that synchronous memory operations initiated on the region of memory that <tt class="ph tt code">ptr</tt> points to will always synchronize. See further documentation in the section titled "API synchronization behavior" to learn
                                 more about cases when synchronous memory operations can exhibit asynchronous behavior.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60d891336d10c16c3ea8140fa581c5446f" shape="rect">CU_POINTER_ATTRIBUTE_BUFFER_ID</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">Returns in <tt class="ph tt code">*data</tt> a buffer ID which is guaranteed to be unique within the process. <tt class="ph tt code">data</tt> must point to an unsigned long long.
                              </p>
                              <p class="p"><tt class="ph tt code">ptr</tt> must be a pointer to memory obtained from a CUDA memory allocation API. Every memory allocation from any of the CUDA memory
                                 allocation APIs will have a unique ID over a process lifetime. Subsequent allocations do not reuse IDs from previous freed
                                 allocations. IDs are only unique within a single process.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60893cfce785d799fb93826537fbb72a1d" shape="rect">CU_POINTER_ATTRIBUTE_IS_MANAGED</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">Returns in <tt class="ph tt code">*data</tt> a boolean that indicates whether the pointer points to managed memory or not.
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60cb7636b0198450ddb390ab87e98d83a0" shape="rect">CU_POINTER_ATTRIBUTE_DEVICE_ORDINAL</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">Returns in <tt class="ph tt code">*data</tt> an integer representing a device ordinal of a device against which the memory was allocated or registered.
                              </p>
                              <p class="p"></p>
                              <p class="p">
                                 Note that for most allocations in the unified virtual address space the host and device pointer for accessing the allocation
                                 will be the same. The exceptions to this are
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p">user memory registered using <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gf0a9fe11544326dabd743b7aa6b54223" title="Registers an existing host memory range for use by CUDA." shape="rect">cuMemHostRegister</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p">host memory allocated using <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g572ca4011bfcb25034888a14d4e035b9" title="Allocates page-locked host memory." shape="rect">cuMemHostAlloc</a> with the <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g7361580951deecace15352c97a210038" shape="rect">CU_MEMHOSTALLOC_WRITECOMBINED</a> flag For these types of allocation there will exist separate, disjoint host and device addresses for accessing the allocation.
                                          In particular
                                       </p>
                                    </li>
                                    <li class="li">
                                       <p class="p">The host address will correspond to an invalid unmapped device address (which will result in an exception if accessed from
                                          the device)
                                       </p>
                                    </li>
                                    <li class="li">
                                       <p class="p">The device address will correspond to an invalid unmapped host address (which will result in an exception if accessed from
                                          the host). For these types of allocations, querying <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60ab17d9902b1b631982ae6a3a9a436fdc" shape="rect">CU_POINTER_ATTRIBUTE_HOST_POINTER</a> and <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60b5446064bbfa484ea8d13025f1573d5d" shape="rect">CU_POINTER_ATTRIBUTE_DEVICE_POINTER</a> may be used to retrieve the host and device addresses from either address.
                                       </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__UNIFIED.html#group__CUDA__UNIFIED_1g89f7ad29a657e574fdea2624b74d138e" title="Set attributes on a previously allocated memory region." shape="rect">cuPointerSetAttribute</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb82d2a09844a58dd9e744dc31e8aa467" title="Allocates device memory." shape="rect">cuMemAlloc</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g89b3f154e17cc89b6eea277dbdf5c93a" title="Frees device memory." shape="rect">cuMemFree</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gdd8311286d2c2691605362c689bc64e0" title="Allocates page-locked host memory." shape="rect">cuMemAllocHost</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g62e0fdbe181dab6b1c90fa1a51c7b92c" title="Frees page-locked host memory." shape="rect">cuMemFreeHost</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g572ca4011bfcb25034888a14d4e035b9" title="Allocates page-locked host memory." shape="rect">cuMemHostAlloc</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gf0a9fe11544326dabd743b7aa6b54223" title="Registers an existing host memory range for use by CUDA." shape="rect">cuMemHostRegister</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g63f450c8125359be87b7623b1c0b2a14" title="Unregisters a memory range that was registered with cuMemHostRegister." shape="rect">cuMemHostUnregister</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__UNIFIED.html#group__CUDART__UNIFIED_1gd89830e17d399c064a2f3c3fa8bb4390" target="_blank" shape="rect">cudaPointerGetAttributes</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__UNIFIED_1gf65e9ea532e311dd049166e4894955ad" id="group__CUDA__UNIFIED_1gf65e9ea532e311dd049166e4894955ad" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuPointerGetAttributes (  unsigned int <span>&nbsp;</span><span class="keyword keyword apiItemName">numAttributes</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc2cce590e35080745e72633dfc6e0b60" title="" shape="rect">CUpointer_attribute</a>*<span>&nbsp;</span><span class="keyword keyword apiItemName">attributes</span>, void**<span>&nbsp;</span><span class="keyword keyword apiItemName">data</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">ptr</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Returns information about a pointer. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">numAttributes</span></tt></dt>
                                 <dd>- Number of attributes to query </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">attributes</span></tt></dt>
                                 <dd>- An array of attributes to query (numAttributes and the number of attributes in this array should match) </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">data</span></tt></dt>
                                 <dd>- A two-dimensional array containing pointers to memory locations where the result of each attribute query will be written
                                    to. 
                                 </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">ptr</span></tt></dt>
                                 <dd>- Pointer 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_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_1ggc6c391505e117393cc2558fff6bfc2e96f047e7215788ca96c81af92a04bfb6c" shape="rect">CUDA_ERROR_INVALID_DEVICE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>The supported attributes are (refer to <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g0c28ed0aff848042bc0533110e45820c" title="Returns information about a pointer." shape="rect">cuPointerGetAttribute</a> for attribute descriptions and restrictions):
                              </p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60f0470fdbd1a5ff72c341f762f49506ab" shape="rect">CU_POINTER_ATTRIBUTE_CONTEXT</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b600409e16293b60b383f30a9b417b2917c" shape="rect">CU_POINTER_ATTRIBUTE_MEMORY_TYPE</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60b5446064bbfa484ea8d13025f1573d5d" shape="rect">CU_POINTER_ATTRIBUTE_DEVICE_POINTER</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60ab17d9902b1b631982ae6a3a9a436fdc" shape="rect">CU_POINTER_ATTRIBUTE_HOST_POINTER</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60db5380c3201afdae3556cce8834504e1" shape="rect">CU_POINTER_ATTRIBUTE_SYNC_MEMOPS</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60d891336d10c16c3ea8140fa581c5446f" shape="rect">CU_POINTER_ATTRIBUTE_BUFFER_ID</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60893cfce785d799fb93826537fbb72a1d" shape="rect">CU_POINTER_ATTRIBUTE_IS_MANAGED</a></p>
                                    </li>
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60cb7636b0198450ddb390ab87e98d83a0" shape="rect">CU_POINTER_ATTRIBUTE_DEVICE_ORDINAL</a></p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">
                                 Unlike <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g0c28ed0aff848042bc0533110e45820c" title="Returns information about a pointer." shape="rect">cuPointerGetAttribute</a>, this function will not return an error when the <tt class="ph tt code">ptr</tt> encountered is not a valid CUDA pointer. Instead, the attributes are assigned default NULL values and CUDA_SUCCESS is returned.
                              </p>
                              <p class="p">If <tt class="ph tt code">ptr</tt> was not allocated by, mapped by, or registered with a <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gf9f5bd81658f866613785b3a0bb7d7d9" shape="rect">CUcontext</a> which uses UVA (Unified Virtual Addressing), <a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc6c391505e117393cc2558fff6bfc2e9a484e9af32c1e9893ff21f0e0191a12d" shape="rect">CUDA_ERROR_INVALID_CONTEXT</a> is returned.
                              </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__UNIFIED.html#group__CUDA__UNIFIED_1g0c28ed0aff848042bc0533110e45820c" title="Returns information about a pointer." shape="rect">cuPointerGetAttribute</a>, <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1g89f7ad29a657e574fdea2624b74d138e" title="Set attributes on a previously allocated memory region." shape="rect">cuPointerSetAttribute</a>, <a class="xref" href="../cuda-runtime-api/group__CUDART__UNIFIED.html#group__CUDART__UNIFIED_1gd89830e17d399c064a2f3c3fa8bb4390" target="_blank" shape="rect">cudaPointerGetAttributes</a></p>
                              <p class="p"></p>
                           </div>
                        </dd>
                        <dt class="description"><a name="group__CUDA__UNIFIED_1g89f7ad29a657e574fdea2624b74d138e" id="group__CUDA__UNIFIED_1g89f7ad29a657e574fdea2624b74d138e" shape="rect">
                              <!-- --></a><span><a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc6c391505e117393cc2558fff6bfc2e9" title="" shape="rect">CUresult</a> cuPointerSetAttribute (  const void*<span>&nbsp;</span><span class="keyword keyword apiItemName">value</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1gc2cce590e35080745e72633dfc6e0b60" title="" shape="rect">CUpointer_attribute</a><span>&nbsp;</span><span class="keyword keyword apiItemName">attribute</span>, <a href="group__CUDA__TYPES.html#group__CUDA__TYPES_1g5e264ce2ad6a38761e7e04921ef771de" title="" shape="rect">CUdeviceptr</a><span>&nbsp;</span><span class="keyword keyword apiItemName">ptr</span> ) </span></dt>
                        <dd class="description">
                           <div class="section">Set attributes on a previously allocated memory region. </div>
                           <div class="section">
                              <h6 class="parameter_header">
                                 Parameters
                                 
                              </h6>
                              <dl class="table-display-params">
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">value</span></tt></dt>
                                 <dd>- Pointer to memory containing the value to be set </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">attribute</span></tt></dt>
                                 <dd>- Pointer attribute to set </dd>
                                 <dt><tt class="code"><span class="keyword keyword apiItemName">ptr</span></tt></dt>
                                 <dd>- Pointer to a memory region allocated using CUDA memory allocation APIs</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_1ggc6c391505e117393cc2558fff6bfc2e96f047e7215788ca96c81af92a04bfb6c" shape="rect">CUDA_ERROR_INVALID_DEVICE</a></p>
                           </div>
                           <div class="section">
                              <h6 class="description_header">Description</h6>
                              <p>The supported attributes are:</p>
                              <p class="p">
                                 <ul class="ul">
                                    <li class="li">
                                       <p class="p"><a class="xref" href="group__CUDA__TYPES.html#group__CUDA__TYPES_1ggc2cce590e35080745e72633dfc6e0b60db5380c3201afdae3556cce8834504e1" shape="rect">CU_POINTER_ATTRIBUTE_SYNC_MEMOPS</a>:
                                       </p>
                                    </li>
                                 </ul>
                              </p>
                              <p class="p">A boolean attribute that can either be set (1) or unset (0). When set, the region of memory that <tt class="ph tt code">ptr</tt> points to is guaranteed to always synchronize memory operations that are synchronous. If there are some previously initiated
                                 synchronous memory operations that are pending when this attribute is set, the function does not return until those memory
                                 operations are complete. See further documentation in the section titled "API synchronization behavior" to learn more about
                                 cases when synchronous memory operations can exhibit asynchronous behavior. <tt class="ph tt code">value</tt> will be considered as a pointer to an unsigned integer to which this attribute is to be set.
                              </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__UNIFIED.html#group__CUDA__UNIFIED_1g0c28ed0aff848042bc0533110e45820c" title="Returns information about a pointer." shape="rect">cuPointerGetAttribute</a>, <a class="xref" href="group__CUDA__UNIFIED.html#group__CUDA__UNIFIED_1gf65e9ea532e311dd049166e4894955ad" title="Returns information about a pointer." shape="rect">cuPointerGetAttributes</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gb82d2a09844a58dd9e744dc31e8aa467" title="Allocates device memory." shape="rect">cuMemAlloc</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g89b3f154e17cc89b6eea277dbdf5c93a" title="Frees device memory." shape="rect">cuMemFree</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gdd8311286d2c2691605362c689bc64e0" title="Allocates page-locked host memory." shape="rect">cuMemAllocHost</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g62e0fdbe181dab6b1c90fa1a51c7b92c" title="Frees page-locked host memory." shape="rect">cuMemFreeHost</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g572ca4011bfcb25034888a14d4e035b9" title="Allocates page-locked host memory." shape="rect">cuMemHostAlloc</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1gf0a9fe11544326dabd743b7aa6b54223" title="Registers an existing host memory range for use by CUDA." shape="rect">cuMemHostRegister</a>, <a class="xref" href="group__CUDA__MEM.html#group__CUDA__MEM_1g63f450c8125359be87b7623b1c0b2a14" title="Unregisters a memory range that was registered with cuMemHostRegister." shape="rect">cuMemHostUnregister</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>