<div dir="ltr">Dan,<div>  Using your approach, I have to specify zero messages in arguments to <span style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">MPI_NEIGHBOR_ALLTOALLV, because I only do communication in one direction in one time.  </span><span style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px">Also, in my graph, there may have edges A->B and B->A. They may have different weights. Using your approach, it is quite confusing.</span></div><div><span style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">  One uses <span style="text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">MPI_NEIGHBOR_ALLTOALLV to have better performance.  We have to keep it in mind.</span></span></div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">--Junchao Zhang</div></div></div>
<br><div class="gmail_quote">On Mon, Jul 23, 2018 at 9:59 AM, HOLMES Daniel <span dir="ltr"><<a href="mailto:d.holmes@epcc.ed.ac.uk" target="_blank">d.holmes@epcc.ed.ac.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">



<div style="word-wrap:break-word">
Hi Junchao Zhang,
<div><br>
</div>
<div>You are correct - the neighbourhood collectives send messages to (and receive messages from) only neighbouring MPI processes, as defined by the virtual topology. However, it is possible to use point-to-point, single-sided, or normal collective
 functions to send (and receive) messages between *any* MPI processes in a communicator, irrespective of the presence/structure of a virtual topology.<br>
<div><br class="m_1473567523782397734webkit-block-placeholder">
</div>
<div>
<div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
For your use-case (if I understand it correctly), you should specify a symmetric graph - each process specifies to MPI_DIST_GRAPH_CREATE_ADJACENT all the processes it wishes to communicate with (both sending and receiving) during subsequent calls to MPI_NEIGHBOR_ALLTOALLV.</div><span class="">
<div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<br class="m_1473567523782397734Apple-interchange-newline">
Cheers,</div>
<div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
Dan.</div>
<div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
—<br>
Dr Daniel Holmes PhD<br>
Applications Consultant in HPC Research<br>
<a href="mailto:d.holmes@epcc.ed.ac.uk" target="_blank">d.holmes@epcc.ed.ac.uk</a><br>
Phone: +44 (0) 131 651 3465<br>
Mobile: +44 (0) 7940 524 088<br>
Address: Room 3415, JCMB, The King’s Buildings, Edinburgh, EH9 3FD</div>
<div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
—</div>
<div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336.</div>
<div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
—</div>
</span></div><div><div class="h5">
<br>
<div>
<blockquote type="cite">
<div>On 23 Jul 2018, at 15:45, Junchao Zhang <<a href="mailto:jczhang@mcs.anl.gov" target="_blank">jczhang@mcs.anl.gov</a>> wrote:</div>
<br class="m_1473567523782397734Apple-interchange-newline">
<div>
<div dir="ltr">Hello, Dan,<br>
 I am interested in MPI_Neighbor_alltoallv. From its arguments, I do not see one can send a message to a neighbor not specified in the graph created by
<span style="font-size:small;text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">
for example, </span>MPI_Dist_graph_<wbr>create_adjacent.</div>
<div class="gmail_extra"><br clear="all">
<div>
<div class="m_1473567523782397734gmail_signature" data-smartmail="gmail_signature">
<div dir="ltr">--Junchao Zhang</div>
</div>
</div>
<br>
<div class="gmail_quote">On Mon, Jul 23, 2018 at 5:51 AM, HOLMES Daniel <span dir="ltr">
<<a href="mailto:d.holmes@epcc.ed.ac.uk" target="_blank">d.holmes@epcc.ed.ac.uk</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word">Hi Junchao Zhang,
<div><br>
</div>
<div>My understanding of the current API for MPI-3.1 is that:</div>
<div><br>
</div>
<div>1) the virtual topology does not actually restrict communication via the communicator to the edges specified in the topology - messages can be sent along any edge in either direction, and even between pairs of processes for which no edge was specified.</div>
<div><br>
</div>
<div>2) the virtual topology can be specified as a symmetric graph - for every ‘forward’ edge (e.g. from A to B), the ‘backward’ edge (i.e. from B to A) can be included as well.</div>
<div><br>
</div>
<div>3) there is already language in the MPI Standard regarding how MPI handles symmetric and non-symmetric graph topologies for neighbourhood collective operations.</div>
<div><br>
</div>
<div>Thus, there is no need to create two distributed graph topology communicators to achieve ‘forward and backward communication along the edges’.<br>
<div>
<div style="font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<br class="m_1473567523782397734m_-3269555800436358659Apple-interchange-newline">
Cheers,</div>
<div style="font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
Dan.</div>
<div style="font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
—<br>
Dr Daniel Holmes PhD<br>
Applications Consultant in HPC Research<br>
<a href="mailto:d.holmes@epcc.ed.ac.uk" target="_blank">d.holmes@epcc.ed.ac.uk</a><br>
Phone: +44 (0) 131 651 3465<br>
Mobile: +44 (0) 7940 524 088<br>
Address: Room 3415, JCMB, The King’s Buildings, Edinburgh, EH9 3FD</div>
<div style="font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
—</div>
<div style="font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336.</div>
<div style="font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
—</div>
</div>
<div>
<div class="m_1473567523782397734h5"><br>
<div>
<blockquote type="cite">
<div>On 15 Jul 2018, at 10:42, Anthony Skjellum <<a href="mailto:tony@runtimecomputing.com" target="_blank">tony@runtimecomputing.com</a>> wrote:</div>
<br class="m_1473567523782397734m_-3269555800436358659Apple-interchange-newline">
<div>
<div dir="ltr">Hi, I just saw this. 
<div><br>
<div>We definitely need to consider this concern.  </div>
<div><br>
</div>
<div>I also need to go review the APIs.</div>
<div><br>
</div>
<div>Thanks,</div>
<div>Tony</div>
<div><br>
</div>
</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Sat, Jul 14, 2018 at 12:27 AM, Junchao Zhang <span dir="ltr">
<<a href="mailto:jczhang@mcs.anl.gov" target="_blank">jczhang@mcs.anl.gov</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div> I want to try MPI neighborhood collectives. I have a communication graph and want to do both forward and backward communication along the edges. With current APIs, it looks I need to create two comm_dist_graphs. It is a waste since MPI implementations
 can do similar optimizations for the two.</div>
<div> Should MPI support this scenario?  Thanks.</div>
<span class="m_1473567523782397734m_-3269555800436358659HOEnZb"><font color="#888888"><br clear="all">
<div>
<div class="m_1473567523782397734m_-3269555800436358659m_-3099374219715359755gmail_signature">
<div dir="ltr">--Junchao Zhang</div>
</div>
</div>
</font></span></div>
<br>
______________________________<wbr>_________________<br>
mpiwg-coll mailing list<br>
<a href="mailto:mpiwg-coll@lists.mpi-forum.org" target="_blank">mpiwg-coll@lists.mpi-forum.org</a><br>
<a href="https://lists.mpi-forum.org/mailman/listinfo/mpiwg-coll" rel="noreferrer" target="_blank">https://lists.mpi-forum.org/ma<wbr>ilman/listinfo/mpiwg-coll</a><br>
<br>
</blockquote>
</div>
<br>
<br clear="all">
<div><br>
</div>
-- <br>
<div class="m_1473567523782397734m_-3269555800436358659gmail_signature" data-smartmail="gmail_signature">
<div dir="ltr">
<div>Tony Skjellum, PhD<br>
RunTime Computing Solutions, LLC<br>
<a href="mailto:tony@runtimecomputing.com" target="_blank">tony@runtimecomputing.com</a><br>
direct: +1-205-918-7514<br>
cell: +1-205-807-4968<br>
</div>
</div>
</div>
</div>
______________________________<wbr>_________________<br>
mpiwg-coll mailing list<br>
<a href="mailto:mpiwg-coll@lists.mpi-forum.org" target="_blank">mpiwg-coll@lists.mpi-forum.org</a><br>
<a href="https://lists.mpi-forum.org/mailman/listinfo/mpiwg-coll" target="_blank">https://lists.mpi-forum.org/ma<wbr>ilman/listinfo/mpiwg-coll</a><br>
</div>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</div>
<br>
The University of Edinburgh is a charitable body, registered in<br>
Scotland, with registration number SC005336.<br>
<br>
______________________________<wbr>_________________<br>
mpiwg-coll mailing list<br>
<a href="mailto:mpiwg-coll@lists.mpi-forum.org" target="_blank">mpiwg-coll@lists.mpi-forum.org</a><br>
<a href="https://lists.mpi-forum.org/mailman/listinfo/mpiwg-coll" rel="noreferrer" target="_blank">https://lists.mpi-forum.org/ma<wbr>ilman/listinfo/mpiwg-coll</a><br>
<br>
</blockquote>
</div>
<br>
</div>
______________________________<wbr>_________________<br>
mpiwg-coll mailing list<br>
<a href="mailto:mpiwg-coll@lists.mpi-forum.org" target="_blank">mpiwg-coll@lists.mpi-forum.org</a><br>
<a href="https://lists.mpi-forum.org/mailman/listinfo/mpiwg-coll" target="_blank">https://lists.mpi-forum.org/<wbr>mailman/listinfo/mpiwg-coll</a><br>
</div>
</blockquote>
</div>
<br>
</div></div></div>
</div>

<br>The University of Edinburgh is a charitable body, registered in<br>
Scotland, with registration number SC005336.<br>
<br>______________________________<wbr>_________________<br>
mpiwg-coll mailing list<br>
<a href="mailto:mpiwg-coll@lists.mpi-forum.org">mpiwg-coll@lists.mpi-forum.org</a><br>
<a href="https://lists.mpi-forum.org/mailman/listinfo/mpiwg-coll" rel="noreferrer" target="_blank">https://lists.mpi-forum.org/<wbr>mailman/listinfo/mpiwg-coll</a><br>
<br></blockquote></div><br></div>