Sophie

Sophie

distrib > Mageia > 2 > i586 > media > nonfree-release > by-pkgid > f86555c654b1f4a4c7ccf47789979868 > files > 1636

nvidia-cuda-toolkit-devel-4.2.9-2.mga2.nonfree.i586.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>NVIDIA CUDA Library: cuMemcpy2DUnaligned</title>
<link href="customdoxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.8 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
  <div class="navpath"><a class="el" href="group__CUDA__MEM.html">Memory Management</a>
  </div>
<table cellspacing="0" cellpadding="0" border="0">
  <tr>
   <td valign="top">
      <div class="navtab">
        <table>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gc2322c70b38c2984536c90ed118bb1d7.html#gc2322c70b38c2984536c90ed118bb1d7">cuArray3DCreate</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gb58549f2f3f390b9e0e7c8f3acd53857.html#gb58549f2f3f390b9e0e7c8f3acd53857">cuArray3DGetDescriptor</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g4192ff387a81c3bd5ed8c391ed62ca24.html#g4192ff387a81c3bd5ed8c391ed62ca24">cuArrayCreate</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g982878affbbc023de84874faac838b0b.html#g982878affbbc023de84874faac838b0b">cuArrayDestroy</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g661fe823dbd37bf11f82a71bd4762acf.html#g661fe823dbd37bf11f82a71bd4762acf">cuArrayGetDescriptor</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g7e0bf2261bb1f21743818d3a287ce9cb.html#g7e0bf2261bb1f21743818d3a287ce9cb">cuDeviceGetByPCIBusId</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g85295e7d9745ab8f0aa80dd1e172acfc.html#g85295e7d9745ab8f0aa80dd1e172acfc">cuDeviceGetPCIBusId</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gd6f5d5bcf6376c6853b64635b0157b9e.html#gd6f5d5bcf6376c6853b64635b0157b9e">cuIpcCloseMemHandle</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gea02eadd12483de5305878b13288a86c.html#gea02eadd12483de5305878b13288a86c">cuIpcGetEventHandle</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g6f1b5be767b275f016523b2ac49ebec1.html#g6f1b5be767b275f016523b2ac49ebec1">cuIpcGetMemHandle</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gf1d525918b6c643b99ca8c8e42e36c2e.html#gf1d525918b6c643b99ca8c8e42e36c2e">cuIpcOpenEventHandle</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_ga8bd126fcff919a0c996b7640f197b79.html#ga8bd126fcff919a0c996b7640f197b79">cuIpcOpenMemHandle</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gb82d2a09844a58dd9e744dc31e8aa467.html#gb82d2a09844a58dd9e744dc31e8aa467">cuMemAlloc</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gdd8311286d2c2691605362c689bc64e0.html#gdd8311286d2c2691605362c689bc64e0">cuMemAllocHost</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gcbe9b033f6c4de80f63cc6e58ed9a45a.html#gcbe9b033f6c4de80f63cc6e58ed9a45a">cuMemAllocPitch</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g8d0ff510f26d4b87bd3a51e731e7f698.html#g8d0ff510f26d4b87bd3a51e731e7f698">cuMemcpy</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g27f885b30c34cc20a663a671dbf6fc27.html#g27f885b30c34cc20a663a671dbf6fc27">cuMemcpy2D</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g4acf155faeb969d9d21f5433d3d0f274.html#g4acf155faeb969d9d21f5433d3d0f274">cuMemcpy2DAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindexHL" href="group__CUDA__MEM_g2fa285d47fd7020e596bfeab3deb651b.html#g2fa285d47fd7020e596bfeab3deb651b">cuMemcpy2DUnaligned</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g4b5238975579f002c0199a3800ca44df.html#g4b5238975579f002c0199a3800ca44df">cuMemcpy3D</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g79f4f3fde6ae0f529568d881d9e11987.html#g79f4f3fde6ae0f529568d881d9e11987">cuMemcpy3DAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g11466fd70cde9329a4e16eb1f258c433.html#g11466fd70cde9329a4e16eb1f258c433">cuMemcpy3DPeer</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gc4e4bfd9f627d3aa3695979e058f1bb8.html#gc4e4bfd9f627d3aa3695979e058f1bb8">cuMemcpy3DPeerAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g5f26aaf5582ade791e5688727a178d78.html#g5f26aaf5582ade791e5688727a178d78">cuMemcpyAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gf81b218c984a31436ec9e23a85fb604a.html#gf81b218c984a31436ec9e23a85fb604a">cuMemcpyAtoA</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g825b3f037f7f51382cae991bae8173fd.html#g825b3f037f7f51382cae991bae8173fd">cuMemcpyAtoD</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gf7ad1edb2539cccc352c6b8b76f657f4.html#gf7ad1edb2539cccc352c6b8b76f657f4">cuMemcpyAtoH</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g64cbd2e60436699aebdd0bdbf14d0f01.html#g64cbd2e60436699aebdd0bdbf14d0f01">cuMemcpyAtoHAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gad6827247af91600b56ce6e2ddb802e1.html#gad6827247af91600b56ce6e2ddb802e1">cuMemcpyDtoA</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g1725774abf8b51b91945f3336b778c8b.html#g1725774abf8b51b91945f3336b778c8b">cuMemcpyDtoD</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g39ea09ba682b8eccc9c3e0c04319b5c8.html#g39ea09ba682b8eccc9c3e0c04319b5c8">cuMemcpyDtoDAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g3480368ee0208a98f75019c9a8450893.html#g3480368ee0208a98f75019c9a8450893">cuMemcpyDtoH</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g56f30236c7c5247f8e061b59d3268362.html#g56f30236c7c5247f8e061b59d3268362">cuMemcpyDtoHAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g57d3d780d165ecc0e3b3ce08e141cd89.html#g57d3d780d165ecc0e3b3ce08e141cd89">cuMemcpyHtoA</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gb5c4863f64f132b4bc2661818b3fd188.html#gb5c4863f64f132b4bc2661818b3fd188">cuMemcpyHtoAAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g4d32266788c440b0220b1a9ba5795169.html#g4d32266788c440b0220b1a9ba5795169">cuMemcpyHtoD</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g1572263fe2597d7ba4f6964597a354a3.html#g1572263fe2597d7ba4f6964597a354a3">cuMemcpyHtoDAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_ge1f5c7771544fee150ada8853c7cbf4a.html#ge1f5c7771544fee150ada8853c7cbf4a">cuMemcpyPeer</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g82fcecb38018e64b98616a8ac30112f2.html#g82fcecb38018e64b98616a8ac30112f2">cuMemcpyPeerAsync</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g89b3f154e17cc89b6eea277dbdf5c93a.html#g89b3f154e17cc89b6eea277dbdf5c93a">cuMemFree</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g62e0fdbe181dab6b1c90fa1a51c7b92c.html#g62e0fdbe181dab6b1c90fa1a51c7b92c">cuMemFreeHost</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g64fee5711274a2a0573a789c94d8299b.html#g64fee5711274a2a0573a789c94d8299b">cuMemGetAddressRange</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g808f555540d0143a331cc42aa98835c0.html#g808f555540d0143a331cc42aa98835c0">cuMemGetInfo</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g572ca4011bfcb25034888a14d4e035b9.html#g572ca4011bfcb25034888a14d4e035b9">cuMemHostAlloc</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g57a39e5cba26af4d06be67fc77cc62f0.html#g57a39e5cba26af4d06be67fc77cc62f0">cuMemHostGetDevicePointer</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g42066246915fcb0400df2a17a851b35f.html#g42066246915fcb0400df2a17a851b35f">cuMemHostGetFlags</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gf0a9fe11544326dabd743b7aa6b54223.html#gf0a9fe11544326dabd743b7aa6b54223">cuMemHostRegister</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g63f450c8125359be87b7623b1c0b2a14.html#g63f450c8125359be87b7623b1c0b2a14">cuMemHostUnregister</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g7d805e610054392a4d11e8a8bf5eb35c.html#g7d805e610054392a4d11e8a8bf5eb35c">cuMemsetD16</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gf731438877dd8ec875e4c43d848c878c.html#gf731438877dd8ec875e4c43d848c878c">cuMemsetD16Async</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g7f561a15a66144fa9f6ab5350edc8a30.html#g7f561a15a66144fa9f6ab5350edc8a30">cuMemsetD2D16</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g64ee197befac3d74d9fefedcf6ef6b10.html#g64ee197befac3d74d9fefedcf6ef6b10">cuMemsetD2D16Async</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g74b359b2d026bfeb7c795b5038d07523.html#g74b359b2d026bfeb7c795b5038d07523">cuMemsetD2D32</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g8a78d3147ac93fac955052c815d9ea3c.html#g8a78d3147ac93fac955052c815d9ea3c">cuMemsetD2D32Async</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_ge88b13e646e2be6ba0e0475ef5205974.html#ge88b13e646e2be6ba0e0475ef5205974">cuMemsetD2D8</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g3f7b6924a3e49c3265b328f534102e97.html#g3f7b6924a3e49c3265b328f534102e97">cuMemsetD2D8Async</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g983e8d8759acd1b64326317481fbf132.html#g983e8d8759acd1b64326317481fbf132">cuMemsetD32</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g58229da5d30f1c0cdf667b320ec2c0f5.html#g58229da5d30f1c0cdf667b320ec2c0f5">cuMemsetD32Async</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_g6e582bf866e9e2fb014297bfaf354d7b.html#g6e582bf866e9e2fb014297bfaf354d7b">cuMemsetD8</a></td></tr>
          <tr><td class="navtab"><a class="qindex" href="group__CUDA__MEM_gaef08a7ccd61112f94e82f2b30d43627.html#gaef08a7ccd61112f94e82f2b30d43627">cuMemsetD8Async</a></td></tr>
        </table>
      </div>
   </td>
   <td valign="top">
<a class="anchor" name="g2fa285d47fd7020e596bfeab3deb651b"></a><!-- doxytag: member="cuda.h::cuMemcpy2DUnaligned" ref="g2fa285d47fd7020e596bfeab3deb651b" args="(const CUDA_MEMCPY2D *pCopy)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__CUDA__TYPES_g09da14df1a751dcbfeccb9cf0073d64c.html#g09da14df1a751dcbfeccb9cf0073d64c">CUresult</a> cuMemcpy2DUnaligned           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structCUDA__MEMCPY2D__st.html">CUDA_MEMCPY2D</a> *&nbsp;</td>
          <td class="paramname"> <em>pCopy</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Perform a 2D memory copy according to the parameters specified in <code>pCopy</code>. The <a class="el" href="group__CUDA__TYPES_gc7616f941854d4e091c5de153338c047.html#gc7616f941854d4e091c5de153338c047">CUDA_MEMCPY2D</a> structure is defined as:<p>
<div class="fragment"><pre class="fragment">   <span class="keyword">typedef</span> <span class="keyword">struct </span><a class="code" href="structCUDA__MEMCPY2D__st.html">CUDA_MEMCPY2D_st</a> {
      <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> srcXInBytes, <a class="code" href="structCUDA__MEMCPY2D__st_620be67748ad30084f249e26bb58d789.html#620be67748ad30084f249e26bb58d789">srcY</a>;
      <a class="code" href="group__CUDA__TYPES_g9e45c622a47315753c4725c101148a81.html#g9e45c622a47315753c4725c101148a81">CUmemorytype</a> <a class="code" href="structCUDA__MEMCPY2D__st_9c8cbec0f85f10d7653f24b79d7b76cd.html#9c8cbec0f85f10d7653f24b79d7b76cd">srcMemoryType</a>;
      <span class="keyword">const</span> <span class="keywordtype">void</span> *<a class="code" href="structCUDA__MEMCPY2D__st_63b7951046622ab6bf0f40cef9688849.html#63b7951046622ab6bf0f40cef9688849">srcHost</a>;
      <a class="code" href="group__CUDA__TYPES_g5e264ce2ad6a38761e7e04921ef771de.html#g5e264ce2ad6a38761e7e04921ef771de">CUdeviceptr</a> <a class="code" href="structCUDA__MEMCPY2D__st_5016184b936eb67144cce5a0987d67da.html#5016184b936eb67144cce5a0987d67da">srcDevice</a>;
      <a class="code" href="group__CUDA__TYPES_gd550651524a56766b60f10f0e7628042.html#gd550651524a56766b60f10f0e7628042">CUarray</a> <a class="code" href="structCUDA__MEMCPY2D__st_da88028619eb81028088fe9bb02d7e1d.html#da88028619eb81028088fe9bb02d7e1d">srcArray</a>;
      <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="structCUDA__MEMCPY2D__st_eef0b0a539bee2c6286fe2b6d7fd0604.html#eef0b0a539bee2c6286fe2b6d7fd0604">srcPitch</a>;
      <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> dstXInBytes, <a class="code" href="structCUDA__MEMCPY2D__st_a360b4a2c8bc1c6b1c7e68d357bbadb0.html#a360b4a2c8bc1c6b1c7e68d357bbadb0">dstY</a>;
      <a class="code" href="group__CUDA__TYPES_g9e45c622a47315753c4725c101148a81.html#g9e45c622a47315753c4725c101148a81">CUmemorytype</a> <a class="code" href="structCUDA__MEMCPY2D__st_b7e5bea217b43d96affd677a702082e5.html#b7e5bea217b43d96affd677a702082e5">dstMemoryType</a>;
      <span class="keywordtype">void</span> *<a class="code" href="structCUDA__MEMCPY2D__st_916251ae0ad7a508d36bc92e6a18a339.html#916251ae0ad7a508d36bc92e6a18a339">dstHost</a>;
      <a class="code" href="group__CUDA__TYPES_g5e264ce2ad6a38761e7e04921ef771de.html#g5e264ce2ad6a38761e7e04921ef771de">CUdeviceptr</a> <a class="code" href="structCUDA__MEMCPY2D__st_c81c6c2ba2cdb23b8d9f0d45ccef3dc7.html#c81c6c2ba2cdb23b8d9f0d45ccef3dc7">dstDevice</a>;
      <a class="code" href="group__CUDA__TYPES_gd550651524a56766b60f10f0e7628042.html#gd550651524a56766b60f10f0e7628042">CUarray</a> <a class="code" href="structCUDA__MEMCPY2D__st_7a043619ea099f5bf95d317fa6b45f36.html#7a043619ea099f5bf95d317fa6b45f36">dstArray</a>;
      <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="structCUDA__MEMCPY2D__st_552ff239ba6b316620fb6d574b0c8d0e.html#552ff239ba6b316620fb6d574b0c8d0e">dstPitch</a>;
      <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="structCUDA__MEMCPY2D__st_85b86eabce81d83186b39eb376224a49.html#85b86eabce81d83186b39eb376224a49">WidthInBytes</a>;
      <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="structCUDA__MEMCPY2D__st_854126b31ec448e4923e5e39456a948f.html#854126b31ec448e4923e5e39456a948f">Height</a>;
   } <a class="code" href="structCUDA__MEMCPY2D__st.html">CUDA_MEMCPY2D</a>;
</pre></div> where:<ul>
<li>srcMemoryType and dstMemoryType specify the type of memory of the source and destination, respectively; <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#g401176319b8c53648d525e8859437790">CUmemorytype_enum</a> is defined as:</li></ul>
<p>
<div class="fragment"><pre class="fragment">   <span class="keyword">typedef</span> <span class="keyword">enum</span> <a class="code" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#g401176319b8c53648d525e8859437790">CUmemorytype_enum</a> {
      <a class="code" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e88594377907f98a88f26eec8490bfc180c5a73e101">CU_MEMORYTYPE_HOST</a> = 0x01,
      <a class="code" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e8859437790ec7e15ba4b111a26adb3487023707299">CU_MEMORYTYPE_DEVICE</a> = 0x02,
      <a class="code" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e8859437790d7f97cd13a156651767607456fe25b66">CU_MEMORYTYPE_ARRAY</a> = 0x03,
      <a class="code" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e88594377907a47ca2de6db5cf82084ad80ce66aa71">CU_MEMORYTYPE_UNIFIED</a> = 0x04
   } <a class="code" href="group__CUDA__TYPES_g9e45c622a47315753c4725c101148a81.html#g9e45c622a47315753c4725c101148a81">CUmemorytype</a>;
</pre></div><p>
<dl class="user" compact><dt><b></b></dt><dd>If srcMemoryType is <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e88594377907a47ca2de6db5cf82084ad80ce66aa71">CU_MEMORYTYPE_UNIFIED</a>, srcDevice and srcPitch specify the (unified virtual address space) base address of the source data and the bytes per row to apply. srcArray is ignored. This value may be used only if unified addressing is supported in the calling context.</dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>If srcMemoryType is <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e88594377907f98a88f26eec8490bfc180c5a73e101">CU_MEMORYTYPE_HOST</a>, srcHost and srcPitch specify the (host) base address of the source data and the bytes per row to apply. srcArray is ignored.</dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>If srcMemoryType is <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e8859437790ec7e15ba4b111a26adb3487023707299">CU_MEMORYTYPE_DEVICE</a>, srcDevice and srcPitch specify the (device) base address of the source data and the bytes per row to apply. srcArray is ignored.</dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>If srcMemoryType is <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e8859437790d7f97cd13a156651767607456fe25b66">CU_MEMORYTYPE_ARRAY</a>, srcArray specifies the handle of the source data. srcHost, srcDevice and srcPitch are ignored.</dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>If dstMemoryType is <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e88594377907a47ca2de6db5cf82084ad80ce66aa71">CU_MEMORYTYPE_UNIFIED</a>, dstDevice and dstPitch specify the (unified virtual address space) base address of the source data and the bytes per row to apply. dstArray is ignored. This value may be used only if unified addressing is supported in the calling context.</dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>If dstMemoryType is <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e88594377907f98a88f26eec8490bfc180c5a73e101">CU_MEMORYTYPE_HOST</a>, dstHost and dstPitch specify the (host) base address of the destination data and the bytes per row to apply. dstArray is ignored.</dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>If dstMemoryType is <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e8859437790ec7e15ba4b111a26adb3487023707299">CU_MEMORYTYPE_DEVICE</a>, dstDevice and dstPitch specify the (device) base address of the destination data and the bytes per row to apply. dstArray is ignored.</dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>If dstMemoryType is <a class="el" href="group__CUDA__TYPES_g401176319b8c53648d525e8859437790.html#gg401176319b8c53648d525e8859437790d7f97cd13a156651767607456fe25b66">CU_MEMORYTYPE_ARRAY</a>, dstArray specifies the handle of the destination data. dstHost, dstDevice and dstPitch are ignored.</dd></dl>
<ul>
<li>srcXInBytes and srcY specify the base address of the source data for the copy.</li></ul>
<p>
<dl class="user" compact><dt><b></b></dt><dd>For host pointers, the starting address is <div class="fragment"><pre class="fragment">  <span class="keywordtype">void</span>* Start = (<span class="keywordtype">void</span>*)((<span class="keywordtype">char</span>*)srcHost+srcY*srcPitch + srcXInBytes);
</pre></div></dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>For device pointers, the starting address is <div class="fragment"><pre class="fragment">  <a class="code" href="group__CUDA__TYPES_g5e264ce2ad6a38761e7e04921ef771de.html#g5e264ce2ad6a38761e7e04921ef771de">CUdeviceptr</a> Start = srcDevice+srcY*srcPitch+srcXInBytes;
</pre></div></dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>For CUDA arrays, srcXInBytes must be evenly divisible by the array element size.</dd></dl>
<ul>
<li>dstXInBytes and dstY specify the base address of the destination data for the copy.</li></ul>
<p>
<dl class="user" compact><dt><b></b></dt><dd>For host pointers, the base address is <div class="fragment"><pre class="fragment">  <span class="keywordtype">void</span>* dstStart = (<span class="keywordtype">void</span>*)((<span class="keywordtype">char</span>*)dstHost+dstY*dstPitch + dstXInBytes);
</pre></div></dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>For device pointers, the starting address is <div class="fragment"><pre class="fragment">  <a class="code" href="group__CUDA__TYPES_g5e264ce2ad6a38761e7e04921ef771de.html#g5e264ce2ad6a38761e7e04921ef771de">CUdeviceptr</a> dstStart = dstDevice+dstY*dstPitch+dstXInBytes;
</pre></div></dd></dl>
<dl class="user" compact><dt><b></b></dt><dd>For CUDA arrays, dstXInBytes must be evenly divisible by the array element size.</dd></dl>
<ul>
<li>WidthInBytes and Height specify the width (in bytes) and height of the 2D copy being performed.</li><li>If specified, srcPitch must be greater than or equal to WidthInBytes + srcXInBytes, and dstPitch must be greater than or equal to WidthInBytes + dstXInBytes.</li></ul>
<p>
<dl class="user" compact><dt><b></b></dt><dd><a class="el" href="group__CUDA__MEM_g27f885b30c34cc20a663a671dbf6fc27.html#g27f885b30c34cc20a663a671dbf6fc27" title="Copies memory for 2D arrays.">cuMemcpy2D()</a> returns an error if any pitch is greater than the maximum allowed (<a class="el" href="group__CUDA__TYPES_g3b9f561d2a42733dde99b2cedcaa413a.html#gg3b9f561d2a42733dde99b2cedcaa413ac1625acc7a2db635bc1efae34030598d">CU_DEVICE_ATTRIBUTE_MAX_PITCH</a>). <a class="el" href="group__CUDA__MEM_gcbe9b033f6c4de80f63cc6e58ed9a45a.html#gcbe9b033f6c4de80f63cc6e58ed9a45a" title="Allocates pitched device memory.">cuMemAllocPitch()</a> passes back pitches that always work with <a class="el" href="group__CUDA__MEM_g27f885b30c34cc20a663a671dbf6fc27.html#g27f885b30c34cc20a663a671dbf6fc27" title="Copies memory for 2D arrays.">cuMemcpy2D()</a>. On intra-device memory copies (device to device, CUDA array to device, CUDA array to CUDA array), <a class="el" href="group__CUDA__MEM_g27f885b30c34cc20a663a671dbf6fc27.html#g27f885b30c34cc20a663a671dbf6fc27" title="Copies memory for 2D arrays.">cuMemcpy2D()</a> may fail for pitches not computed by <a class="el" href="group__CUDA__MEM_gcbe9b033f6c4de80f63cc6e58ed9a45a.html#gcbe9b033f6c4de80f63cc6e58ed9a45a" title="Allocates pitched device memory.">cuMemAllocPitch()</a>. <a class="el" href="group__CUDA__MEM_g2fa285d47fd7020e596bfeab3deb651b.html#g2fa285d47fd7020e596bfeab3deb651b" title="Copies memory for 2D arrays.">cuMemcpy2DUnaligned()</a> does not have this restriction, but may run significantly slower in the cases where <a class="el" href="group__CUDA__MEM_g27f885b30c34cc20a663a671dbf6fc27.html#g27f885b30c34cc20a663a671dbf6fc27" title="Copies memory for 2D arrays.">cuMemcpy2D()</a> would have returned an error code.</dd></dl>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pCopy</em>&nbsp;</td><td>- Parameters for the memory copy</td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd><a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaaa0eed720f8a87cd1c5fd1c453bc7a03d">CUDA_SUCCESS</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaaacf52f132faf29b473cdda6061f0f44a">CUDA_ERROR_DEINITIALIZED</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaa8feb999f0af99b4a25ab26b3866f4df8">CUDA_ERROR_NOT_INITIALIZED</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaaa484e9af32c1e9893ff21f0e0191a12d">CUDA_ERROR_INVALID_CONTEXT</a>, <a class="el" href="group__CUDA__TYPES_g0cdead942fd5028d157641eef6bdeeaa.html#gg0cdead942fd5028d157641eef6bdeeaa90696c86fcee1f536a1ec7d25867feeb">CUDA_ERROR_INVALID_VALUE</a> </dd></dl>
<dl class="note" compact><dt><b>Note:</b></dt><dd>Note that this function may also return error codes from previous, asynchronous launches.</dd></dl>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="group__CUDA__MEM_gc2322c70b38c2984536c90ed118bb1d7.html#gc2322c70b38c2984536c90ed118bb1d7" title="Creates a 3D CUDA array.">cuArray3DCreate</a>, <a class="el" href="group__CUDA__MEM_gb58549f2f3f390b9e0e7c8f3acd53857.html#gb58549f2f3f390b9e0e7c8f3acd53857" title="Get a 3D CUDA array descriptor.">cuArray3DGetDescriptor</a>, <a class="el" href="group__CUDA__MEM_g4192ff387a81c3bd5ed8c391ed62ca24.html#g4192ff387a81c3bd5ed8c391ed62ca24" title="Creates a 1D or 2D CUDA array.">cuArrayCreate</a>, <a class="el" href="group__CUDA__MEM_g982878affbbc023de84874faac838b0b.html#g982878affbbc023de84874faac838b0b" title="Destroys a CUDA array.">cuArrayDestroy</a>, <a class="el" href="group__CUDA__MEM_g661fe823dbd37bf11f82a71bd4762acf.html#g661fe823dbd37bf11f82a71bd4762acf" title="Get a 1D or 2D CUDA array descriptor.">cuArrayGetDescriptor</a>, <a class="el" href="group__CUDA__MEM_gb82d2a09844a58dd9e744dc31e8aa467.html#gb82d2a09844a58dd9e744dc31e8aa467" title="Allocates device memory.">cuMemAlloc</a>, <a class="el" href="group__CUDA__MEM_gdd8311286d2c2691605362c689bc64e0.html#gdd8311286d2c2691605362c689bc64e0" title="Allocates page-locked host memory.">cuMemAllocHost</a>, <a class="el" href="group__CUDA__MEM_gcbe9b033f6c4de80f63cc6e58ed9a45a.html#gcbe9b033f6c4de80f63cc6e58ed9a45a" title="Allocates pitched device memory.">cuMemAllocPitch</a>, <a class="el" href="group__CUDA__MEM_g27f885b30c34cc20a663a671dbf6fc27.html#g27f885b30c34cc20a663a671dbf6fc27" title="Copies memory for 2D arrays.">cuMemcpy2D</a>, <a class="el" href="group__CUDA__MEM_g4acf155faeb969d9d21f5433d3d0f274.html#g4acf155faeb969d9d21f5433d3d0f274" title="Copies memory for 2D arrays.">cuMemcpy2DAsync</a>, <a class="el" href="group__CUDA__MEM_g4b5238975579f002c0199a3800ca44df.html#g4b5238975579f002c0199a3800ca44df" title="Copies memory for 3D arrays.">cuMemcpy3D</a>, <a class="el" href="group__CUDA__MEM_g79f4f3fde6ae0f529568d881d9e11987.html#g79f4f3fde6ae0f529568d881d9e11987" title="Copies memory for 3D arrays.">cuMemcpy3DAsync</a>, <a class="el" href="group__CUDA__MEM_gf81b218c984a31436ec9e23a85fb604a.html#gf81b218c984a31436ec9e23a85fb604a" title="Copies memory from Array to Array.">cuMemcpyAtoA</a>, <a class="el" href="group__CUDA__MEM_g825b3f037f7f51382cae991bae8173fd.html#g825b3f037f7f51382cae991bae8173fd" title="Copies memory from Array to Device.">cuMemcpyAtoD</a>, <a class="el" href="group__CUDA__MEM_gf7ad1edb2539cccc352c6b8b76f657f4.html#gf7ad1edb2539cccc352c6b8b76f657f4" title="Copies memory from Array to Host.">cuMemcpyAtoH</a>, <a class="el" href="group__CUDA__MEM_g64cbd2e60436699aebdd0bdbf14d0f01.html#g64cbd2e60436699aebdd0bdbf14d0f01" title="Copies memory from Array to Host.">cuMemcpyAtoHAsync</a>, <a class="el" href="group__CUDA__MEM_gad6827247af91600b56ce6e2ddb802e1.html#gad6827247af91600b56ce6e2ddb802e1" title="Copies memory from Device to Array.">cuMemcpyDtoA</a>, <a class="el" href="group__CUDA__MEM_g1725774abf8b51b91945f3336b778c8b.html#g1725774abf8b51b91945f3336b778c8b" title="Copies memory from Device to Device.">cuMemcpyDtoD</a>, <a class="el" href="group__CUDA__MEM_g39ea09ba682b8eccc9c3e0c04319b5c8.html#g39ea09ba682b8eccc9c3e0c04319b5c8" title="Copies memory from Device to Device.">cuMemcpyDtoDAsync</a>, <a class="el" href="group__CUDA__MEM_g3480368ee0208a98f75019c9a8450893.html#g3480368ee0208a98f75019c9a8450893" title="Copies memory from Device to Host.">cuMemcpyDtoH</a>, <a class="el" href="group__CUDA__MEM_g56f30236c7c5247f8e061b59d3268362.html#g56f30236c7c5247f8e061b59d3268362" title="Copies memory from Device to Host.">cuMemcpyDtoHAsync</a>, <a class="el" href="group__CUDA__MEM_g57d3d780d165ecc0e3b3ce08e141cd89.html#g57d3d780d165ecc0e3b3ce08e141cd89" title="Copies memory from Host to Array.">cuMemcpyHtoA</a>, <a class="el" href="group__CUDA__MEM_gb5c4863f64f132b4bc2661818b3fd188.html#gb5c4863f64f132b4bc2661818b3fd188" title="Copies memory from Host to Array.">cuMemcpyHtoAAsync</a>, <a class="el" href="group__CUDA__MEM_g4d32266788c440b0220b1a9ba5795169.html#g4d32266788c440b0220b1a9ba5795169" title="Copies memory from Host to Device.">cuMemcpyHtoD</a>, <a class="el" href="group__CUDA__MEM_g1572263fe2597d7ba4f6964597a354a3.html#g1572263fe2597d7ba4f6964597a354a3" title="Copies memory from Host to Device.">cuMemcpyHtoDAsync</a>, <a class="el" href="group__CUDA__MEM_g89b3f154e17cc89b6eea277dbdf5c93a.html#g89b3f154e17cc89b6eea277dbdf5c93a" title="Frees device memory.">cuMemFree</a>, <a class="el" href="group__CUDA__MEM_g62e0fdbe181dab6b1c90fa1a51c7b92c.html#g62e0fdbe181dab6b1c90fa1a51c7b92c" title="Frees page-locked host memory.">cuMemFreeHost</a>, <a class="el" href="group__CUDA__MEM_g64fee5711274a2a0573a789c94d8299b.html#g64fee5711274a2a0573a789c94d8299b" title="Get information on memory allocations.">cuMemGetAddressRange</a>, <a class="el" href="group__CUDA__MEM_g808f555540d0143a331cc42aa98835c0.html#g808f555540d0143a331cc42aa98835c0" title="Gets free and total memory.">cuMemGetInfo</a>, <a class="el" href="group__CUDA__MEM_g572ca4011bfcb25034888a14d4e035b9.html#g572ca4011bfcb25034888a14d4e035b9" title="Allocates page-locked host memory.">cuMemHostAlloc</a>, <a class="el" href="group__CUDA__MEM_g57a39e5cba26af4d06be67fc77cc62f0.html#g57a39e5cba26af4d06be67fc77cc62f0" title="Passes back device pointer of mapped pinned memory.">cuMemHostGetDevicePointer</a>, <a class="el" href="group__CUDA__MEM_ge88b13e646e2be6ba0e0475ef5205974.html#ge88b13e646e2be6ba0e0475ef5205974" title="Initializes device memory.">cuMemsetD2D8</a>, <a class="el" href="group__CUDA__MEM_g7f561a15a66144fa9f6ab5350edc8a30.html#g7f561a15a66144fa9f6ab5350edc8a30" title="Initializes device memory.">cuMemsetD2D16</a>, <a class="el" href="group__CUDA__MEM_g74b359b2d026bfeb7c795b5038d07523.html#g74b359b2d026bfeb7c795b5038d07523" title="Initializes device memory.">cuMemsetD2D32</a>, <a class="el" href="group__CUDA__MEM_g6e582bf866e9e2fb014297bfaf354d7b.html#g6e582bf866e9e2fb014297bfaf354d7b" title="Initializes device memory.">cuMemsetD8</a>, <a class="el" href="group__CUDA__MEM_g7d805e610054392a4d11e8a8bf5eb35c.html#g7d805e610054392a4d11e8a8bf5eb35c" title="Initializes device memory.">cuMemsetD16</a>, <a class="el" href="group__CUDA__MEM_g983e8d8759acd1b64326317481fbf132.html#g983e8d8759acd1b64326317481fbf132" title="Initializes device memory.">cuMemsetD32</a> </dd></dl>

</div>
</div><p>
    </td>
  </tr>
</table>
</div>
<hr size="1"><address style="text-align: right;"><small>
Generated by Doxygen for NVIDIA CUDA Library &nbsp;<a
href="http://www.nvidia.com/cuda"><img src="nvidia_logo.jpg" alt="NVIDIA" align="middle" border="0" height="80"></a></small></address>
</body>
</html>