f052f43b3b
Change-Id: If04d1155173fba8d3e050f3259da8b3edc60e076
438 Zeilen
37 KiB
HTML
438 Zeilen
37 KiB
HTML
<!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">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.8.6"/>
|
|
<title>HIP: Heterogenous-computing Interface for Portability: Stream Management</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<script type="text/javascript">
|
|
$(document).ready(function() { searchBox.OnSelectItem(0); });
|
|
</script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td style="padding-left: 0.5em;">
|
|
<div id="projectname">HIP: Heterogenous-computing Interface for Portability
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.6 -->
|
|
<script type="text/javascript">
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
</script>
|
|
<div id="navrow1" class="tabs">
|
|
<ul class="tablist">
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
|
<li><a href="pages.html"><span>Related Pages</span></a></li>
|
|
<li><a href="modules.html"><span>Modules</span></a></li>
|
|
<li><a href="annotated.html"><span>Classes</span></a></li>
|
|
<li><a href="files.html"><span>Files</span></a></li>
|
|
<li>
|
|
<div id="MSearchBox" class="MSearchBoxInactive">
|
|
<span class="left">
|
|
<img id="MSearchSelect" src="search/mag_sel.png"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
alt=""/>
|
|
<input type="text" id="MSearchField" value="Search" accesskey="S"
|
|
onfocus="searchBox.OnSearchFieldFocus(true)"
|
|
onblur="searchBox.OnSearchFieldFocus(false)"
|
|
onkeyup="searchBox.OnSearchFieldChange(event)"/>
|
|
</span><span class="right">
|
|
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
|
|
</span>
|
|
</div>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark"> </span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark"> </span>Macros</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(10)"><span class="SelectionMark"> </span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(11)"><span class="SelectionMark"> </span>Pages</a></div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#typedef-members">Typedefs</a> |
|
|
<a href="#func-members">Functions</a> </div>
|
|
<div class="headertitle">
|
|
<div class="title">Stream Management<div class="ingroups"><a class="el" href="group__API.html">HIP API</a></div></div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
|
|
Typedefs</h2></td></tr>
|
|
<tr class="memitem:gadd389da2e3926a8ff17658d029015dcd"><td class="memItemLeft" align="right" valign="top">typedef void(* </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#gadd389da2e3926a8ff17658d029015dcd">hipStreamCallback_t</a> )(<a class="el" href="classihipStream__t.html">hipStream_t</a> stream, <a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> status, void *userData)</td></tr>
|
|
<tr class="separator:gadd389da2e3926a8ff17658d029015dcd"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
|
|
Functions</h2></td></tr>
|
|
<tr class="memitem:gaff5b62d6e9502d80879f7176f4d03102"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#gaff5b62d6e9502d80879f7176f4d03102">hipStreamCreate</a> (<a class="el" href="classihipStream__t.html">hipStream_t</a> *stream)</td></tr>
|
|
<tr class="memdesc:gaff5b62d6e9502d80879f7176f4d03102"><td class="mdescLeft"> </td><td class="mdescRight">Create an asynchronous stream. <a href="#gaff5b62d6e9502d80879f7176f4d03102">More...</a><br/></td></tr>
|
|
<tr class="separator:gaff5b62d6e9502d80879f7176f4d03102"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:gaf2382e3cc6632332a8983a0f58e43494"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#gaf2382e3cc6632332a8983a0f58e43494">hipStreamCreateWithFlags</a> (<a class="el" href="classihipStream__t.html">hipStream_t</a> *stream, unsigned int flags)</td></tr>
|
|
<tr class="memdesc:gaf2382e3cc6632332a8983a0f58e43494"><td class="mdescLeft"> </td><td class="mdescRight">Create an asynchronous stream. <a href="#gaf2382e3cc6632332a8983a0f58e43494">More...</a><br/></td></tr>
|
|
<tr class="separator:gaf2382e3cc6632332a8983a0f58e43494"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga3076a3499ed2c7821311006100bb95ec"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#ga3076a3499ed2c7821311006100bb95ec">hipStreamDestroy</a> (<a class="el" href="classihipStream__t.html">hipStream_t</a> stream)</td></tr>
|
|
<tr class="memdesc:ga3076a3499ed2c7821311006100bb95ec"><td class="mdescLeft"> </td><td class="mdescRight">Destroys the specified stream. <a href="#ga3076a3499ed2c7821311006100bb95ec">More...</a><br/></td></tr>
|
|
<tr class="separator:ga3076a3499ed2c7821311006100bb95ec"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga925b39ff78d3b5fd458bd9e2cade9f4e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#ga925b39ff78d3b5fd458bd9e2cade9f4e">hipStreamQuery</a> (<a class="el" href="classihipStream__t.html">hipStream_t</a> stream)</td></tr>
|
|
<tr class="memdesc:ga925b39ff78d3b5fd458bd9e2cade9f4e"><td class="mdescLeft"> </td><td class="mdescRight">Return <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a> if all of the operations in the specified <code>stream</code> have completed, or <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aa9638063c8746a9d1fda2b2069a0a9f1" title="Indicates that asynchronous operations enqueued earlier are not ready. This is not actually an error...">hipErrorNotReady</a> if not. <a href="#ga925b39ff78d3b5fd458bd9e2cade9f4e">More...</a><br/></td></tr>
|
|
<tr class="separator:ga925b39ff78d3b5fd458bd9e2cade9f4e"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:gabbfb9f573a6ebe8c478605ecb5504a74"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#gabbfb9f573a6ebe8c478605ecb5504a74">hipStreamSynchronize</a> (<a class="el" href="classihipStream__t.html">hipStream_t</a> stream)</td></tr>
|
|
<tr class="memdesc:gabbfb9f573a6ebe8c478605ecb5504a74"><td class="mdescLeft"> </td><td class="mdescRight">Wait for all commands in stream to complete. <a href="#gabbfb9f573a6ebe8c478605ecb5504a74">More...</a><br/></td></tr>
|
|
<tr class="separator:gabbfb9f573a6ebe8c478605ecb5504a74"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:gacdd84c8f8ef1539c96c57c1d5bcae633"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#gacdd84c8f8ef1539c96c57c1d5bcae633">hipStreamWaitEvent</a> (<a class="el" href="classihipStream__t.html">hipStream_t</a> stream, <a class="el" href="structihipEvent__t.html">hipEvent_t</a> event, unsigned int flags)</td></tr>
|
|
<tr class="memdesc:gacdd84c8f8ef1539c96c57c1d5bcae633"><td class="mdescLeft"> </td><td class="mdescRight">Make the specified compute stream wait for an event. <a href="#gacdd84c8f8ef1539c96c57c1d5bcae633">More...</a><br/></td></tr>
|
|
<tr class="separator:gacdd84c8f8ef1539c96c57c1d5bcae633"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga3249555a26439591b8873f70b39bb116"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#ga3249555a26439591b8873f70b39bb116">hipStreamGetFlags</a> (<a class="el" href="classihipStream__t.html">hipStream_t</a> stream, unsigned int *flags)</td></tr>
|
|
<tr class="memdesc:ga3249555a26439591b8873f70b39bb116"><td class="mdescLeft"> </td><td class="mdescRight">Return flags associated with this stream. <a href="#ga3249555a26439591b8873f70b39bb116">More...</a><br/></td></tr>
|
|
<tr class="separator:ga3249555a26439591b8873f70b39bb116"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ga3e098cd7478828b2104abb41a7bb00d3"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__Stream.html#ga3e098cd7478828b2104abb41a7bb00d3">hipStreamAddCallback</a> (<a class="el" href="classihipStream__t.html">hipStream_t</a> stream, <a class="el" href="group__Stream.html#gadd389da2e3926a8ff17658d029015dcd">hipStreamCallback_t</a> callback, void *userData, unsigned int flags)</td></tr>
|
|
<tr class="memdesc:ga3e098cd7478828b2104abb41a7bb00d3"><td class="mdescLeft"> </td><td class="mdescRight">Adds a callback to be called on the host after all currently enqueued items in the stream have completed. For each cudaStreamAddCallback call, a callback will be executed exactly once. The callback will block later work in the stream until it is finished. <a href="#ga3e098cd7478828b2104abb41a7bb00d3">More...</a><br/></td></tr>
|
|
<tr class="separator:ga3e098cd7478828b2104abb41a7bb00d3"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
|
<h2>----------------------------------------------------------------------------------------------— </h2>
|
|
<p>The following Stream APIs are not (yet) supported in HIP:</p>
|
|
<ul>
|
|
<li>cudaStreamAddCallback</li>
|
|
<li>cudaStreamAttachMemAsync</li>
|
|
<li>cudaStreamCreateWithPriority</li>
|
|
<li>cudaStreamGetPriority</li>
|
|
<li>cudaStreamWaitEvent </li>
|
|
</ul>
|
|
<h2 class="groupheader">Typedef Documentation</h2>
|
|
<a class="anchor" id="gadd389da2e3926a8ff17658d029015dcd"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">typedef void(* hipStreamCallback_t)(<a class="el" href="classihipStream__t.html">hipStream_t</a> stream, <a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> status, void *userData)</td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
<p>Stream CallBack struct </p>
|
|
|
|
</div>
|
|
</div>
|
|
<h2 class="groupheader">Function Documentation</h2>
|
|
<a class="anchor" id="ga3e098cd7478828b2104abb41a7bb00d3"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> hipStreamAddCallback </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classihipStream__t.html">hipStream_t</a> </td>
|
|
<td class="paramname"><em>stream</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype"><a class="el" href="group__Stream.html#gadd389da2e3926a8ff17658d029015dcd">hipStreamCallback_t</a> </td>
|
|
<td class="paramname"><em>callback</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">void * </td>
|
|
<td class="paramname"><em>userData</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">unsigned int </td>
|
|
<td class="paramname"><em>flags</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Adds a callback to be called on the host after all currently enqueued items in the stream have completed. For each cudaStreamAddCallback call, a callback will be executed exactly once. The callback will block later work in the stream until it is finished. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">stream</td><td>- Stream to add callback to </td></tr>
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">callback</td><td>- The function to call once preceding stream operations are complete </td></tr>
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">userData</td><td>- User specified data to be passed to the callback function </td></tr>
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">flags</td><td>- Reserved for future use, must be 0 </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a88e525a7c8f35552dfada58e9f2f6d3a" title="Resource handle (hipEvent_t or hipStream_t) invalid. ">hipErrorInvalidResourceHandle</a>, #hipErrorNotSupported</dd></dl>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__Stream.html#gaff5b62d6e9502d80879f7176f4d03102" title="Create an asynchronous stream. ">hipStreamCreate</a>, <a class="el" href="group__Stream.html#gaf2382e3cc6632332a8983a0f58e43494" title="Create an asynchronous stream. ">hipStreamCreateWithFlags</a>, <a class="el" href="group__Stream.html#ga925b39ff78d3b5fd458bd9e2cade9f4e" title="Return hipSuccess if all of the operations in the specified stream have completed, or hipErrorNotReady if not. ">hipStreamQuery</a>, <a class="el" href="group__Stream.html#gabbfb9f573a6ebe8c478605ecb5504a74" title="Wait for all commands in stream to complete. ">hipStreamSynchronize</a>, <a class="el" href="group__Stream.html#gacdd84c8f8ef1539c96c57c1d5bcae633" title="Make the specified compute stream wait for an event. ">hipStreamWaitEvent</a>, <a class="el" href="group__Stream.html#ga3076a3499ed2c7821311006100bb95ec" title="Destroys the specified stream. ">hipStreamDestroy</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="gaff5b62d6e9502d80879f7176f4d03102"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> hipStreamCreate </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classihipStream__t.html">hipStream_t</a> * </td>
|
|
<td class="paramname"><em>stream</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Create an asynchronous stream. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramdir">[in,out]</td><td class="paramname">stream</td><td>Valid pointer to hipStream_t. This function writes the memory with the newly created stream. </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a1e8215fe1108a508bad3944bce7b4d83" title="One or more of the parameters passed to the API call is NULL or not in an acceptable range...">hipErrorInvalidValue</a></dd></dl>
|
|
<p>Create a new asynchronous stream. <code>stream</code> returns an opaque handle that can be used to reference the newly created stream in subsequent hipStream* commands. The stream is allocated on the heap and will remain allocated even if the handle goes out-of-scope. To release the memory used by the stream, applicaiton must call hipStreamDestroy.</p>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a1e8215fe1108a508bad3944bce7b4d83" title="One or more of the parameters passed to the API call is NULL or not in an acceptable range...">hipErrorInvalidValue</a></dd></dl>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__Stream.html#gaf2382e3cc6632332a8983a0f58e43494" title="Create an asynchronous stream. ">hipStreamCreateWithFlags</a>, <a class="el" href="group__Stream.html#gabbfb9f573a6ebe8c478605ecb5504a74" title="Wait for all commands in stream to complete. ">hipStreamSynchronize</a>, <a class="el" href="group__Stream.html#gacdd84c8f8ef1539c96c57c1d5bcae633" title="Make the specified compute stream wait for an event. ">hipStreamWaitEvent</a>, <a class="el" href="group__Stream.html#ga3076a3499ed2c7821311006100bb95ec" title="Destroys the specified stream. ">hipStreamDestroy</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="gaf2382e3cc6632332a8983a0f58e43494"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> hipStreamCreateWithFlags </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classihipStream__t.html">hipStream_t</a> * </td>
|
|
<td class="paramname"><em>stream</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">unsigned int </td>
|
|
<td class="paramname"><em>flags</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Create an asynchronous stream. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramdir">[in,out]</td><td class="paramname">stream</td><td>Pointer to new stream </td></tr>
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">flags</td><td>to control stream creation. </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a1e8215fe1108a508bad3944bce7b4d83" title="One or more of the parameters passed to the API call is NULL or not in an acceptable range...">hipErrorInvalidValue</a></dd></dl>
|
|
<p>Create a new asynchronous stream. <code>stream</code> returns an opaque handle that can be used to reference the newly created stream in subsequent hipStream* commands. The stream is allocated on the heap and will remain allocated even if the handle goes out-of-scope. To release the memory used by the stream, applicaiton must call hipStreamDestroy. Flags controls behavior of the stream. See <a class="el" href="group__GlobalDefs.html#ga6df5f70eb976836ab3598cacf0ffcdf9" title="Flags that can be used with hipStreamCreateWithFlags. ">hipStreamDefault</a>, <a class="el" href="group__GlobalDefs.html#gaaba9ae995d9b43b7d1ee70c6fa12c57d" title="Stream does not implicitly synchronize with null stream. ">hipStreamNonBlocking</a>.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__Stream.html#gaff5b62d6e9502d80879f7176f4d03102" title="Create an asynchronous stream. ">hipStreamCreate</a>, <a class="el" href="group__Stream.html#gabbfb9f573a6ebe8c478605ecb5504a74" title="Wait for all commands in stream to complete. ">hipStreamSynchronize</a>, <a class="el" href="group__Stream.html#gacdd84c8f8ef1539c96c57c1d5bcae633" title="Make the specified compute stream wait for an event. ">hipStreamWaitEvent</a>, <a class="el" href="group__Stream.html#ga3076a3499ed2c7821311006100bb95ec" title="Destroys the specified stream. ">hipStreamDestroy</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ga3076a3499ed2c7821311006100bb95ec"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> hipStreamDestroy </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classihipStream__t.html">hipStream_t</a> </td>
|
|
<td class="paramname"><em>stream</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Destroys the specified stream. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramdir">[in,out]</td><td class="paramname">stream</td><td>Valid pointer to hipStream_t. This function writes the memory with the newly created stream. </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a> <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a88e525a7c8f35552dfada58e9f2f6d3a" title="Resource handle (hipEvent_t or hipStream_t) invalid. ">hipErrorInvalidResourceHandle</a></dd></dl>
|
|
<p>Destroys the specified stream.</p>
|
|
<p>If commands are still executing on the specified stream, some may complete execution before the queue is deleted.</p>
|
|
<p>The queue may be destroyed while some commands are still inflight, or may wait for all commands queued to the stream before destroying it.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__Stream.html#gaff5b62d6e9502d80879f7176f4d03102" title="Create an asynchronous stream. ">hipStreamCreate</a>, <a class="el" href="group__Stream.html#gaf2382e3cc6632332a8983a0f58e43494" title="Create an asynchronous stream. ">hipStreamCreateWithFlags</a>, <a class="el" href="group__Stream.html#ga925b39ff78d3b5fd458bd9e2cade9f4e" title="Return hipSuccess if all of the operations in the specified stream have completed, or hipErrorNotReady if not. ">hipStreamQuery</a>, <a class="el" href="group__Stream.html#gacdd84c8f8ef1539c96c57c1d5bcae633" title="Make the specified compute stream wait for an event. ">hipStreamWaitEvent</a>, <a class="el" href="group__Stream.html#gabbfb9f573a6ebe8c478605ecb5504a74" title="Wait for all commands in stream to complete. ">hipStreamSynchronize</a></dd></dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a88e525a7c8f35552dfada58e9f2f6d3a" title="Resource handle (hipEvent_t or hipStream_t) invalid. ">hipErrorInvalidResourceHandle</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ga3249555a26439591b8873f70b39bb116"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> hipStreamGetFlags </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classihipStream__t.html">hipStream_t</a> </td>
|
|
<td class="paramname"><em>stream</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">unsigned int * </td>
|
|
<td class="paramname"><em>flags</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Return flags associated with this stream. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">stream</td><td>stream to be queried </td></tr>
|
|
<tr><td class="paramdir">[in,out]</td><td class="paramname">flags</td><td>Pointer to an unsigned integer in which the stream's flags are returned </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a1e8215fe1108a508bad3944bce7b4d83" title="One or more of the parameters passed to the API call is NULL or not in an acceptable range...">hipErrorInvalidValue</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a88e525a7c8f35552dfada58e9f2f6d3a" title="Resource handle (hipEvent_t or hipStream_t) invalid. ">hipErrorInvalidResourceHandle</a></dd>
|
|
<dd>
|
|
<a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a> <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a1e8215fe1108a508bad3944bce7b4d83" title="One or more of the parameters passed to the API call is NULL or not in an acceptable range...">hipErrorInvalidValue</a> <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a88e525a7c8f35552dfada58e9f2f6d3a" title="Resource handle (hipEvent_t or hipStream_t) invalid. ">hipErrorInvalidResourceHandle</a></dd></dl>
|
|
<p>Return flags associated with this stream in *<code>flags</code>.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__Stream.html#gaf2382e3cc6632332a8983a0f58e43494" title="Create an asynchronous stream. ">hipStreamCreateWithFlags</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="ga925b39ff78d3b5fd458bd9e2cade9f4e"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> hipStreamQuery </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classihipStream__t.html">hipStream_t</a> </td>
|
|
<td class="paramname"><em>stream</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Return <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a> if all of the operations in the specified <code>stream</code> have completed, or <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aa9638063c8746a9d1fda2b2069a0a9f1" title="Indicates that asynchronous operations enqueued earlier are not ready. This is not actually an error...">hipErrorNotReady</a> if not. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">stream</td><td>stream to query</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aa9638063c8746a9d1fda2b2069a0a9f1" title="Indicates that asynchronous operations enqueued earlier are not ready. This is not actually an error...">hipErrorNotReady</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a88e525a7c8f35552dfada58e9f2f6d3a" title="Resource handle (hipEvent_t or hipStream_t) invalid. ">hipErrorInvalidResourceHandle</a></dd></dl>
|
|
<p>This is thread-safe and returns a snapshot of the current state of the queue. However, if other host threads are sending work to the stream, the status may change immediately after the function is called. It is typically used for debug.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__Stream.html#gaff5b62d6e9502d80879f7176f4d03102" title="Create an asynchronous stream. ">hipStreamCreate</a>, <a class="el" href="group__Stream.html#gaf2382e3cc6632332a8983a0f58e43494" title="Create an asynchronous stream. ">hipStreamCreateWithFlags</a>, <a class="el" href="group__Stream.html#gacdd84c8f8ef1539c96c57c1d5bcae633" title="Make the specified compute stream wait for an event. ">hipStreamWaitEvent</a>, <a class="el" href="group__Stream.html#gabbfb9f573a6ebe8c478605ecb5504a74" title="Wait for all commands in stream to complete. ">hipStreamSynchronize</a>, <a class="el" href="group__Stream.html#ga3076a3499ed2c7821311006100bb95ec" title="Destroys the specified stream. ">hipStreamDestroy</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="gabbfb9f573a6ebe8c478605ecb5504a74"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> hipStreamSynchronize </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classihipStream__t.html">hipStream_t</a> </td>
|
|
<td class="paramname"><em>stream</em></td><td>)</td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Wait for all commands in stream to complete. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">stream</td><td>stream identifier.</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a88e525a7c8f35552dfada58e9f2f6d3a" title="Resource handle (hipEvent_t or hipStream_t) invalid. ">hipErrorInvalidResourceHandle</a></dd></dl>
|
|
<p>If the null stream is specified, this command blocks until all This command honors the hipDeviceLaunchBlocking flag, which controls whether the wait is active or blocking. This command is host-synchronous : the host will block until the stream is empty.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__Stream.html#gaff5b62d6e9502d80879f7176f4d03102" title="Create an asynchronous stream. ">hipStreamCreate</a>, <a class="el" href="group__Stream.html#gaf2382e3cc6632332a8983a0f58e43494" title="Create an asynchronous stream. ">hipStreamCreateWithFlags</a>, <a class="el" href="group__Stream.html#gacdd84c8f8ef1539c96c57c1d5bcae633" title="Make the specified compute stream wait for an event. ">hipStreamWaitEvent</a>, <a class="el" href="group__Stream.html#ga3076a3499ed2c7821311006100bb95ec" title="Destroys the specified stream. ">hipStreamDestroy</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
<a class="anchor" id="gacdd84c8f8ef1539c96c57c1d5bcae633"></a>
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname"><a class="el" href="group__GlobalDefs.html#gadf5010f6e140a53ecbdf949e73e87594">hipError_t</a> hipStreamWaitEvent </td>
|
|
<td>(</td>
|
|
<td class="paramtype"><a class="el" href="classihipStream__t.html">hipStream_t</a> </td>
|
|
<td class="paramname"><em>stream</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype"><a class="el" href="structihipEvent__t.html">hipEvent_t</a> </td>
|
|
<td class="paramname"><em>event</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">unsigned int </td>
|
|
<td class="paramname"><em>flags</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
|
|
<p>Make the specified compute stream wait for an event. </p>
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">stream</td><td>stream to make wait. </td></tr>
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">event</td><td>event to wait on </td></tr>
|
|
<tr><td class="paramdir">[in]</td><td class="paramname">flags</td><td>control operation [must be 0]</td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594aadfbdb847b149723c684ebd764556063" title="Successful completion. ">hipSuccess</a>, <a class="el" href="group__GlobalDefs.html#ggadf5010f6e140a53ecbdf949e73e87594a88e525a7c8f35552dfada58e9f2f6d3a" title="Resource handle (hipEvent_t or hipStream_t) invalid. ">hipErrorInvalidResourceHandle</a></dd></dl>
|
|
<p>This function inserts a wait operation into the specified stream. All future work submitted to <code>stream</code> will wait until <code>event</code> reports completion before beginning execution. This function is host-asynchronous and the function may return before the wait has completed.</p>
|
|
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="group__Stream.html#gaff5b62d6e9502d80879f7176f4d03102" title="Create an asynchronous stream. ">hipStreamCreate</a>, <a class="el" href="group__Stream.html#gaf2382e3cc6632332a8983a0f58e43494" title="Create an asynchronous stream. ">hipStreamCreateWithFlags</a>, <a class="el" href="group__Stream.html#gabbfb9f573a6ebe8c478605ecb5504a74" title="Wait for all commands in stream to complete. ">hipStreamSynchronize</a>, <a class="el" href="group__Stream.html#ga3076a3499ed2c7821311006100bb95ec" title="Destroys the specified stream. ">hipStreamDestroy</a> </dd></dl>
|
|
|
|
</div>
|
|
</div>
|
|
</div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated on Mon Dec 19 2016 04:03:43 for HIP: Heterogenous-computing Interface for Portability by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.6
|
|
</small></address>
|
|
</body>
|
|
</html>
|