You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
125 lines
5.3 KiB
HTML
125 lines
5.3 KiB
HTML
5 years ago
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||
|
"http://www.w3.org/TR/html4/loose.dtd">
|
||
|
<html >
|
||
|
<head><title>psb_sum — Global sum</title>
|
||
|
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
||
|
<meta name="generator" content="TeX4ht (http://www.tug.org/tex4ht/)">
|
||
|
<meta name="originator" content="TeX4ht (http://www.tug.org/tex4ht/)">
|
||
|
<!-- html,3 -->
|
||
|
<meta name="src" content="userhtml.tex">
|
||
|
<link rel="stylesheet" type="text/css" href="userhtml.css">
|
||
|
</head><body
|
||
|
>
|
||
|
<!--l. 325--><div class="crosslinks"><p class="noindent">[<a
|
||
|
href="userhtmlsu70.html" >next</a>] [<a
|
||
|
href="userhtmlsu65.html" >prev</a>] [<a
|
||
|
href="userhtmlsu65.html#tailuserhtmlsu65.html" >prev-tail</a>] [<a
|
||
|
href="userhtmlsu63.html#tailuserhtmlsu66.html">tail</a>] [<a
|
||
|
href="userhtmlsu59.html#userhtmlsu69.html" >up</a>] </p></div>
|
||
|
<h4 class="subsectionHead"><span class="titlemark">7.10 </span> <a
|
||
|
id="x78-1150007.10"></a>psb_sum — Global sum</h4>
|
||
|
|
||
|
|
||
|
|
||
|
<div class="verbatim" id="verbatim-93">
|
||
|
call psb_sum(icontxt, dat, root)
|
||
|
</div>
|
||
|
<!--l. 329--><p class="nopar" >
|
||
|
<!--l. 331--><p class="indent" > This subroutine implements a sum reduction operation based on the underlying
|
||
|
communication library.
|
||
|
<dl class="description"><dt class="description">
|
||
|
<span
|
||
|
class="cmbx-10">Type:</span> </dt><dd
|
||
|
class="description">Synchronous.
|
||
|
</dd><dt class="description">
|
||
|
<span
|
||
|
class="cmbx-10">On Entry</span> </dt><dd
|
||
|
class="description">
|
||
|
</dd><dt class="description">
|
||
|
<span
|
||
|
class="cmbx-10">icontxt</span> </dt><dd
|
||
|
class="description">the communication context identifying the virtual parallel machine.<br
|
||
|
class="newline" />Scope: <span
|
||
|
class="cmbx-10">global</span>.<br
|
||
|
class="newline" />Type: <span
|
||
|
class="cmbx-10">required</span>.<br
|
||
|
class="newline" />Intent: <span
|
||
|
class="cmbx-10">in</span>.<br
|
||
|
class="newline" />Specified as: an integer variable.
|
||
|
</dd><dt class="description">
|
||
|
<span
|
||
|
class="cmbx-10">dat</span> </dt><dd
|
||
|
class="description">The local contribution to the global sum.<br
|
||
|
class="newline" />Scope: <span
|
||
|
class="cmbx-10">global</span>.<br
|
||
|
class="newline" />Type: <span
|
||
|
class="cmbx-10">required</span>.<br
|
||
|
class="newline" />Intent: <span
|
||
|
class="cmbx-10">inout</span>.<br
|
||
|
class="newline" />Specified as: an integer, real or complex variable, which may be a scalar, or
|
||
|
a rank 1 or 2 array.  Type, kind, rank and size must agree on all processes.
|
||
|
</dd><dt class="description">
|
||
|
<span
|
||
|
class="cmbx-10">root</span> </dt><dd
|
||
|
class="description">Process to hold the final sum, or <span
|
||
|
class="cmsy-10">-</span>1 to make it available on all processes.<br
|
||
|
class="newline" />Scope: <span
|
||
|
class="cmbx-10">global</span>.<br
|
||
|
class="newline" />Type: <span
|
||
|
class="cmbx-10">optional</span>.<br
|
||
|
class="newline" />Intent: <span
|
||
|
class="cmbx-10">in</span>.<br
|
||
|
class="newline" />Specified as: an integer value <span
|
||
|
class="cmsy-10">-</span>1 <span
|
||
|
class="cmmi-10"><</span>= <span
|
||
|
class="cmmi-10">root <</span>= <span
|
||
|
class="cmmi-10">np </span><span
|
||
|
class="cmsy-10">- </span>1, default -1.  </dd></dl>
|
||
|
<!--l. 358--><p class="indent" >
|
||
|
<dl class="description"><dt class="description">
|
||
|
<span
|
||
|
class="cmbx-10">On Return</span> </dt><dd
|
||
|
class="description">
|
||
|
</dd><dt class="description">
|
||
|
<span
|
||
|
class="cmbx-10">dat</span> </dt><dd
|
||
|
class="description">On destination process(es), the result of the sum operation.<br
|
||
|
class="newline" />Scope: <span
|
||
|
class="cmbx-10">global</span>.<br
|
||
|
class="newline" />Type: <span
|
||
|
class="cmbx-10">required</span>.<br
|
||
|
class="newline" />Intent: <span
|
||
|
class="cmbx-10">inout</span>.<br
|
||
|
class="newline" />Specified as: an integer, real or complex variable, which may be a scalar,
|
||
|
or a rank 1 or 2 array. <br
|
||
|
class="newline" />Type, kind, rank and size must agree on all processes.</dd></dl>
|
||
|
<!--l. 369--><p class="noindent" ><span
|
||
|
class="cmbx-12">Notes</span>
|
||
|
|
||
|
|
||
|
|
||
|
<ol class="enumerate1" >
|
||
|
<li
|
||
|
class="enumerate" id="x78-115002x1">The <span class="obeylines-h"><span class="verb"><span
|
||
|
class="cmtt-10">dat</span></span></span> argument is both input and output, and its value may be changed
|
||
|
even on processes different from the final result destination.
|
||
|
</li>
|
||
|
<li
|
||
|
class="enumerate" id="x78-115004x2">The <span class="obeylines-h"><span class="verb"><span
|
||
|
class="cmtt-10">dat</span></span></span> argument may also be a long integer scalar.</li></ol>
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
<!--l. 379--><div class="crosslinks"><p class="noindent">[<a
|
||
|
href="userhtmlsu70.html" >next</a>] [<a
|
||
|
href="userhtmlsu65.html" >prev</a>] [<a
|
||
|
href="userhtmlsu65.html#tailuserhtmlsu65.html" >prev-tail</a>] [<a
|
||
|
href="userhtmlsu66.html" >front</a>] [<a
|
||
|
href="userhtmlsu59.html#userhtmlsu69.html" >up</a>] </p></div>
|
||
|
<!--l. 379--><p class="indent" > <a
|
||
|
id="tailuserhtmlsu66.html"></a>
|
||
|
</body></html>
|