Files
MPIonCell/documentation/developer/html/db/dc2/group__broadcast.html
T
2017-10-26 19:57:24 +02:00

174 lines
15 KiB
HTML
Executable File

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>MPI On Cell (Documentation): Collective Communication</title>
<link href="../../doxygen.css" rel="stylesheet" type="text/css">
<link href="../../tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="../../main.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="../../files.html"><span>Files</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>Collective Communication<br>
<small>
[<a class="el" href="../../d3/d9e/group__end__user.html">End-User Documentation</a>]</small>
</h1>
<p>
<div class="dynheader">
Collaboration diagram for Collective Communication:</div>
<div class="dynsection">
<center><table><tr><td><img src="../../db/dc2/group__broadcast.png" border="0" alt="" usemap="#d9/dff/db_2dc2_2group____broadcast_map">
<map name="d9/dff/db_2dc2_2group____broadcast_map">
<area shape="rect" href="../../d3/d9e/group__end__user.html" title="This section describes the public API provided by the MOC&#45;library." alt="" coords="7,5,172,32"></map></td></tr></table></center>
</div>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Communication that involves a group of processes.
<p>
A collective operation is normally executed by having all processes in the group call the communication routine, with matching arguments. Since there are no means for creating groups currently implemented, the only available groups are MOC_COMM_WORLD and MOC_COMM_SELF.
<p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/dc2/group__broadcast.html#gfd25e9a19a1ad4032fdf3703531167d6">MOC_Bcast</a> (void *buffer, int count, <a class="el" href="../../dc/d6e/group__p2p__datatype.html#gb4e45f15c08578bd3fc97c0cca2a509a">MOC_Datatype</a> datatype, int root, <a class="el" href="../../d1/dd1/group__comm__mgt.html#g3d2b8a9af65bff5f79d02bda13616767">MOC_Comm</a> comm)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Broadcasts a message from the process with rank "root" to all other processes of the group. <a href="#gfd25e9a19a1ad4032fdf3703531167d6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/dc2/group__broadcast.html#g110b00d5a4d9f970ddf8e9bd4c2d8834">MOC_Barrier</a> (<a class="el" href="../../d1/dd1/group__comm__mgt.html#g3d2b8a9af65bff5f79d02bda13616767">MOC_Comm</a> comm)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Blocks the caller until all processes in the communicator have called it; that is, the call returns at any process only after all members of the communicator have entered the call. <a href="#g110b00d5a4d9f970ddf8e9bd4c2d8834"></a><br></td></tr>
</table>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="g110b00d5a4d9f970ddf8e9bd4c2d8834"></a><!-- doxytag: member="moc.h::MOC_Barrier" ref="g110b00d5a4d9f970ddf8e9bd4c2d8834" args="(MOC_Comm comm)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int MOC_Barrier </td>
<td>(</td>
<td class="paramtype"><a class="el" href="../../d1/dd1/group__comm__mgt.html#g3d2b8a9af65bff5f79d02bda13616767">MOC_Comm</a>&nbsp;</td>
<td class="paramname"> <em>comm</em> </td>
<td>&nbsp;)&nbsp;</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Blocks the caller until all processes in the communicator have called it; that is, the call returns at any process only after all members of the communicator have entered the call.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>comm</em>&nbsp;</td><td><b>in</b> communicator of message </td></tr>
</table>
</dl>
<dl compact><dt><b>Return values:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>MOC_SUCCESS</em>&nbsp;</td><td>No error; MPI routine completed successfully. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>...</em>&nbsp;</td><td>error-code </td></tr>
</table>
</dl>
<p>Definition at line <a class="el" href="../../dc/d5d/moc__barrier__ppu_8c-source.html#l00011">11</a> of file <a class="el" href="../../dc/d5d/moc__barrier__ppu_8c-source.html">moc_barrier_ppu.c</a>.</p>
<p>References <a class="el" href="../../d7/d1f/imoc__buffer__malloc_8c-source.html#l00056">__attribute__()</a>, <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00033">moc_node_handle_ppu_struct::comm_size</a>, <a class="el" href="../../df/dd4/structmoc__message__envelope__struct.html#38288113f9b7adee1e444850112ff807">moc_message_envelope_struct::flags</a>, <a class="el" href="../../dc/d5d/moc__barrier__ppu_8c-source.html#l00009">IMOC_BARRIER_TAG</a>, <a class="el" href="../../d0/d87/imoc__macros_8h-source.html#l00019">IMOC_EA_REMOTE_QUEUE</a>, <a class="el" href="../../d0/d87/imoc__macros_8h-source.html#l00034">IMOC_EA_REMOTE_QUEUE_ENTRY</a>, <a class="el" href="../../de/dbb/imoc__get__entry_8c-source.html#l00013">IMOC_get_entry()</a>, <a class="el" href="../../d1/d2a/imoc__get__free__entry_8c-source.html#l00009">IMOC_getFreeEntry()</a>, <a class="el" href="../../db/db7/imoc__macros__ppu_8h-source.html#l00025">IMOC_LS_REMOTE_QUEUE</a>, <a class="el" href="../../d4/d9b/imoc_8h-source.html#l00049">MEMCPY_GET_TRESHOLD</a>, <a class="el" href="../../d7/de1/moc_8h-source.html#l00301">MOC_COMM_SELF</a>, <a class="el" href="../../d7/de1/moc_8h-source.html#l00296">MOC_COMM_WORLD</a>, <a class="el" href="../../d3/d95/moc__error__codes_8h-source.html#l00035">MOC_ERR_COMM</a>, <a class="el" href="../../d3/d95/moc__error__codes_8h-source.html#l00047">MOC_ERR_INTERN</a>, <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00106">moc_ppu_thread_count</a>, <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00123">moc_spu_thread_list</a>, <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00052">node_handle</a>, <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00034">moc_node_handle_ppu_struct::queue_size</a>, <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00032">moc_node_handle_ppu_struct::rank</a>, <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00078">moc_spu_thread_struct::speid</a>, and <a class="el" href="../../d6/d2c/imoc__core_8h-source.html#l00095">moc_message_envelope_struct::value</a>.</p>
<p>
<div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
<p><center><img src="../../db/dc2/group__broadcast_g110b00d5a4d9f970ddf8e9bd4c2d8834_cgraph.png" border="0" usemap="#db/dc2/group__broadcast_g110b00d5a4d9f970ddf8e9bd4c2d8834_cgraph_map" alt=""></center>
<map name="db/dc2/group__broadcast_g110b00d5a4d9f970ddf8e9bd4c2d8834_cgraph_map">
<area shape="rect" href="../../d3/dd3/group__internal__p2p__bmalloc.html#gad8750c7ba3d6da9c137c2c462d2c531" title="void bmalloc_print_nodes() { if (!bmalloc_first_node) printf(&quot;No nodes in list\\n&quot;);..." alt="" coords="169,5,265,32"><area shape="rect" href="../../d8/d88/group__internal__p2p__main.html#g8980da77fa506e9a6d503c8c6eba68e2" title="Get the next valid message&#45;envelope from &quot;source&quot; with specified &quot;tag&quot;..." alt="" coords="160,56,275,83"><area shape="rect" href="../../d8/d88/group__internal__p2p__main.html#g2a948cdecce651ae6cc1b0c0ddb1b750" title="Get next free entry in message&#45;queue (a local copy of the message&#45;queue has to be..." alt="" coords="149,107,285,133"></map>
</div>
</div>
</div><p>
<a class="anchor" name="gfd25e9a19a1ad4032fdf3703531167d6"></a><!-- doxytag: member="moc.h::MOC_Bcast" ref="gfd25e9a19a1ad4032fdf3703531167d6" args="(void *buffer, int count, MOC_Datatype datatype, int root, MOC_Comm comm)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int MOC_Bcast </td>
<td>(</td>
<td class="paramtype">void *&nbsp;</td>
<td class="paramname"> <em>buffer</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>count</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="../../dc/d6e/group__p2p__datatype.html#gb4e45f15c08578bd3fc97c0cca2a509a">MOC_Datatype</a>&nbsp;</td>
<td class="paramname"> <em>datatype</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>root</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="../../d1/dd1/group__comm__mgt.html#g3d2b8a9af65bff5f79d02bda13616767">MOC_Comm</a>&nbsp;</td>
<td class="paramname"> <em>comm</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Broadcasts a message from the process with rank "root" to all other processes of the group.
<p>
<dl class="note" compact><dt><b>Note:</b></dt><dd>The broadcast-message can also be received by a MOC_Recv using MOC_BCAST_TAG.</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>buffer</em>&nbsp;</td><td><b>inout</b> starting address of buffer </td></tr>
<tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td><b>in</b> number of elements to be send or received </td></tr>
<tr><td valign="top"></td><td valign="top"><em>datatype</em>&nbsp;</td><td><b>in</b> Type of elements to be send or received </td></tr>
<tr><td valign="top"></td><td valign="top"><em>root</em>&nbsp;</td><td><b>in</b> rank of the process who sends the broadcast-message </td></tr>
<tr><td valign="top"></td><td valign="top"><em>comm</em>&nbsp;</td><td><b>in</b> communicator of message </td></tr>
</table>
</dl>
<p>
Sending branch<p>
Receiving Branch
<p>Definition at line <a class="el" href="../../da/d19/moc__bcast_8c-source.html#l00009">9</a> of file <a class="el" href="../../da/d19/moc__bcast_8c-source.html">moc_bcast.c</a>.</p>
<p>References <a class="el" href="../../d7/de1/moc_8h-source.html#l00018">MOC_BCAST_TAG</a>, <a class="el" href="../../d7/de1/moc_8h-source.html#l00301">MOC_COMM_SELF</a>, <a class="el" href="../../d5/d4e/moc__isend_8c-source.html#l00018">MOC_ISend()</a>, <a class="el" href="../../d8/dbc/moc__recv__ppu_8c-source.html#l00011">MOC_Recv()</a>, <a class="el" href="../../de/d33/moc__wait_8c-source.html#l00011">MOC_Wait()</a>, <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00052">node_handle</a>, and <a class="el" href="../../db/d45/imoc__core__ppu_8h-source.html#l00032">moc_node_handle_ppu_struct::rank</a>.</p>
<p>
<div class="dynheader">
Here is the call graph for this function:</div>
<div class="dynsection">
<p><center><img src="../../db/dc2/group__broadcast_gfd25e9a19a1ad4032fdf3703531167d6_cgraph.png" border="0" usemap="#db/dc2/group__broadcast_gfd25e9a19a1ad4032fdf3703531167d6_cgraph_map" alt=""></center>
<map name="db/dc2/group__broadcast_gfd25e9a19a1ad4032fdf3703531167d6_cgraph_map">
<area shape="rect" href="../../d7/d62/group__p2p__imm.html#gd88773e68570adfad9f99159c69502af" title="Performs a non&#45;blocking standard mode send operation." alt="" coords="148,183,239,209"><area shape="rect" href="../../d0/d64/group__p2p__main.html#g30c532510cffd36acd1b9b0b3edb3832" title="Performs a blocking standard mode receive operation." alt="" coords="151,81,236,108"><area shape="rect" href="../../d7/d62/group__p2p__imm.html#g68043e4a0893fdc25c67f87bae1015a6" title="Wait till a non&#45;blocking communication has been completed." alt="" coords="151,259,236,285"><area shape="rect" href="../../de/d84/group__p2p__buffered.html#g307bf844e1416c7c021e4a3468209d0b" title="Performs a blocking buffered mode send operation." alt="" coords="351,208,447,235"><area shape="rect" href="../../d7/d62/group__p2p__imm.html#gc148ff9b9bee69164139425a7df53697" title="Performs a non&#45;blocking synchronous mode send operation." alt="" coords="349,157,448,184"><area shape="rect" href="../../d3/dd3/group__internal__p2p__bmalloc.html#gad8750c7ba3d6da9c137c2c462d2c531" title="void bmalloc_print_nodes() { if (!bmalloc_first_node) printf(&quot;No nodes in list\\n&quot;);..." alt="" coords="577,56,673,83"><area shape="rect" href="../../d3/dd3/group__internal__p2p__bmalloc.html#g5295b372d853993b2e6cfb6912a0ee41" title="Allocate buffer&#45;space." alt="" coords="572,208,679,235"><area shape="rect" href="../../d8/d88/group__internal__p2p__main.html#g2a948cdecce651ae6cc1b0c0ddb1b750" title="Get next free entry in message&#45;queue (a local copy of the message&#45;queue has to be..." alt="" coords="557,107,693,133"><area shape="rect" href="../../d8/d88/group__internal__p2p__main.html#g409bdbea503611cf04829413d15830df" title="Get free message&#45;ID." alt="" coords="561,157,689,184"><area shape="rect" href="../../d2/de2/group__internal__p2p__dma.html#gb48c58191a7cf4d3e502d1c7a6c0ab9c" title="Internal wrapper&#45;function for a blocking DMA&#45;put operation." alt="" coords="569,259,681,285"><area shape="rect" href="../../d2/de2/group__internal__p2p__dma.html#g53d36c567e4c98e5d258a7857096e7ab" title="Internal wrapper&#45;function for a blocking DMA&#45;get operation." alt="" coords="343,5,455,32"><area shape="rect" href="../../d8/d88/group__internal__p2p__main.html#g8980da77fa506e9a6d503c8c6eba68e2" title="Get the next valid message&#45;envelope from &quot;source&quot; with specified &quot;tag&quot;..." alt="" coords="341,107,456,133"><area shape="rect" href="../../d2/de2/group__internal__p2p__dma.html#g57b89667357146b299f32bd114e0e5ad" title="Waits till a IMOC_iget_data or IMOC_iput_data is completed." alt="" coords="341,309,456,336"><area shape="rect" href="../../d8/d88/group__internal__p2p__main.html#g8675f9552168f2dd8926cad5ac00be69" title="Wait till message with message&#45;ID mid has been received." alt="" coords="288,259,509,285"><area shape="rect" href="../../d2/de2/group__internal__p2p__dma.html#gf465203c58c5a8066a7ef3ee91b15cec" title="Releases a reserved tag." alt="" coords="565,309,685,336"></map>
</div>
</div>
</div><p>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Thu Feb 12 13:50:57 2009 for MPI On Cell (Documentation) by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="../../doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6 </small></address>
</body>
</html>