Statistiques
| Révision :

root / www / HPL_logsort.html

Historique | Voir | Annoter | Télécharger (2,88 ko)

1 1 equemene
<HTML>
2 1 equemene
<HEAD>
3 1 equemene
<TITLE>HPL_logsort HPL 2.0 Library Functions September 10, 2008</TITLE>
4 1 equemene
</HEAD>
5 1 equemene
6 1 equemene
<BODY BGCOLOR="WHITE" TEXT = "#000000" LINK = "#0000ff" VLINK = "#000099"
7 1 equemene
      ALINK = "#ffff00">
8 1 equemene
9 1 equemene
<H1>Name</H1>
10 1 equemene
<B>HPL_logsort</B> Sort the processes in logarithmic order.
11 1 equemene
12 1 equemene
<H1>Synopsis</H1>
13 1 equemene
<CODE>#include "hpl.h"</CODE><BR><BR>
14 1 equemene
<CODE>void</CODE>
15 1 equemene
<CODE>HPL_logsort(</CODE>
16 1 equemene
<CODE>const int</CODE>
17 1 equemene
<CODE>NPROCS</CODE>,
18 1 equemene
<CODE>const int</CODE>
19 1 equemene
<CODE>ICURROC</CODE>,
20 1 equemene
<CODE>int *</CODE>
21 1 equemene
<CODE>IPLEN</CODE>,
22 1 equemene
<CODE>int *</CODE>
23 1 equemene
<CODE>IPMAP</CODE>,
24 1 equemene
<CODE>int *</CODE>
25 1 equemene
<CODE>IPMAPM1</CODE>
26 1 equemene
<CODE>);</CODE>
27 1 equemene
28 1 equemene
<H1>Description</H1>
29 1 equemene
<B>HPL_logsort</B>
30 1 equemene
computes an array  IPMAP  and  its inverse  IPMAPM1  that
31 1 equemene
contain  the logarithmic sorted processes id with repect to the local
32 1 equemene
number of rows of  U  that they own. This is necessary to ensure that
33 1 equemene
the logarithmic spreading of U is optimal in terms of number of steps
34 1 equemene
and communication volume as well.  In other words,  the larget pieces
35 1 equemene
of U will be sent a minimal number of times.
36 1 equemene
37 1 equemene
<H1>Arguments</H1>
38 1 equemene
<PRE>
39 1 equemene
NPROCS  (global input)                const int
40 1 equemene
        On entry, NPROCS  specifies the number of process rows in the
41 1 equemene
        process grid. NPROCS is at least one.
42 1 equemene
</PRE>
43 1 equemene
<PRE>
44 1 equemene
ICURROC (global input)                const int
45 1 equemene
        On entry, ICURROC is the source process row.
46 1 equemene
</PRE>
47 1 equemene
<PRE>
48 1 equemene
IPLEN   (global input/output)         int *
49 1 equemene
        On entry, IPLEN is an array of dimension NPROCS+1,  such that
50 1 equemene
        IPLEN[0] is 0, and IPLEN[i] contains the number of rows of U,
51 1 equemene
        that process i-1 has.  On exit,  IPLEN[i]  is  the number  of
52 1 equemene
        rows of U  in the processes before process IPMAP[i] after the
53 1 equemene
        sort,  with  the convention that  IPLEN[NPROCS] is  the total
54 1 equemene
        number  of rows  of the panel.  In other words,  IPLEN[i+1] -
55 1 equemene
        IPLEN[i] is  the  number of rows of A that should be moved to
56 1 equemene
        the process IPMAP[i].  IPLEN  is such that the number of rows
57 1 equemene
        of  the  source process  row is IPLEN[1] - IPLEN[0],  and the
58 1 equemene
        remaining  entries  of  this  array  are  sorted  so that the
59 1 equemene
        quantities IPLEN[i+1]-IPLEN[i] are logarithmically sorted.
60 1 equemene
</PRE>
61 1 equemene
<PRE>
62 1 equemene
IPMAP   (global output)               int *
63 1 equemene
        On entry,  IPMAP  is an array of dimension  NPROCS.  On exit,
64 1 equemene
        array contains  the logarithmic mapping of the processes.  In
65 1 equemene
        other words, IPMAP[myroc] is the corresponding sorted process
66 1 equemene
        coordinate.
67 1 equemene
</PRE>
68 1 equemene
<PRE>
69 1 equemene
IPMAPM1 (global output)               int *
70 1 equemene
        On entry, IPMAPM1  is an array of dimension NPROCS.  On exit,
71 1 equemene
        this  array  contains  the inverse of the logarithmic mapping
72 1 equemene
        contained  in  IPMAP:  IPMAPM1[ IPMAP[i] ] = i,  for all i in
73 1 equemene
        [0.. NPROCS)
74 1 equemene
</PRE>
75 1 equemene
76 1 equemene
<H1>See Also</H1>
77 1 equemene
<A HREF="HPL_plindx1.html">HPL_plindx1</A>,
78 1 equemene
<A HREF="HPL_plindx10.html">HPL_plindx10</A>,
79 1 equemene
<A HREF="HPL_pdlaswp01N.html">HPL_pdlaswp01N</A>,
80 1 equemene
<A HREF="HPL_pdlaswp01T.html">HPL_pdlaswp01T</A>.
81 1 equemene
82 1 equemene
</BODY>
83 1 equemene
</HTML>