Statistiques
| Révision :

root / www / HPL_logsort.html

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

1
<HTML>
2
<HEAD>
3
<TITLE>HPL_logsort HPL 2.0 Library Functions September 10, 2008</TITLE> 
4
</HEAD>
5

    
6
<BODY BGCOLOR="WHITE" TEXT = "#000000" LINK = "#0000ff" VLINK = "#000099"
7
      ALINK = "#ffff00">
8

    
9
<H1>Name</H1>
10
<B>HPL_logsort</B> Sort the processes in logarithmic order.
11

    
12
<H1>Synopsis</H1>
13
<CODE>#include "hpl.h"</CODE><BR><BR>
14
<CODE>void</CODE>
15
<CODE>HPL_logsort(</CODE>
16
<CODE>const int</CODE>
17
<CODE>NPROCS</CODE>,
18
<CODE>const int</CODE>
19
<CODE>ICURROC</CODE>,
20
<CODE>int *</CODE>
21
<CODE>IPLEN</CODE>,
22
<CODE>int *</CODE>
23
<CODE>IPMAP</CODE>,
24
<CODE>int *</CODE>
25
<CODE>IPMAPM1</CODE>
26
<CODE>);</CODE>
27

    
28
<H1>Description</H1>
29
<B>HPL_logsort</B>
30
computes an array  IPMAP  and  its inverse  IPMAPM1  that
31
contain  the logarithmic sorted processes id with repect to the local
32
number of rows of  U  that they own. This is necessary to ensure that
33
the logarithmic spreading of U is optimal in terms of number of steps
34
and communication volume as well.  In other words,  the larget pieces
35
of U will be sent a minimal number of times.
36

    
37
<H1>Arguments</H1>
38
<PRE>
39
NPROCS  (global input)                const int
40
        On entry, NPROCS  specifies the number of process rows in the
41
        process grid. NPROCS is at least one.
42
</PRE>
43
<PRE>
44
ICURROC (global input)                const int
45
        On entry, ICURROC is the source process row.
46
</PRE>
47
<PRE>
48
IPLEN   (global input/output)         int *
49
        On entry, IPLEN is an array of dimension NPROCS+1,  such that
50
        IPLEN[0] is 0, and IPLEN[i] contains the number of rows of U,
51
        that process i-1 has.  On exit,  IPLEN[i]  is  the number  of
52
        rows of U  in the processes before process IPMAP[i] after the
53
        sort,  with  the convention that  IPLEN[NPROCS] is  the total
54
        number  of rows  of the panel.  In other words,  IPLEN[i+1] -
55
        IPLEN[i] is  the  number of rows of A that should be moved to
56
        the process IPMAP[i].  IPLEN  is such that the number of rows
57
        of  the  source process  row is IPLEN[1] - IPLEN[0],  and the
58
        remaining  entries  of  this  array  are  sorted  so that the
59
        quantities IPLEN[i+1]-IPLEN[i] are logarithmically sorted.
60
</PRE>
61
<PRE>
62
IPMAP   (global output)               int *
63
        On entry,  IPMAP  is an array of dimension  NPROCS.  On exit,
64
        array contains  the logarithmic mapping of the processes.  In
65
        other words, IPMAP[myroc] is the corresponding sorted process
66
        coordinate.
67
</PRE>
68
<PRE>
69
IPMAPM1 (global output)               int *
70
        On entry, IPMAPM1  is an array of dimension NPROCS.  On exit,
71
        this  array  contains  the inverse of the logarithmic mapping
72
        contained  in  IPMAP:  IPMAPM1[ IPMAP[i] ] = i,  for all i in
73
        [0.. NPROCS)
74
</PRE>
75

    
76
<H1>See Also</H1>
77
<A HREF="HPL_plindx1.html">HPL_plindx1</A>,
78
<A HREF="HPL_plindx10.html">HPL_plindx10</A>,
79
<A HREF="HPL_pdlaswp01N.html">HPL_pdlaswp01N</A>,
80
<A HREF="HPL_pdlaswp01T.html">HPL_pdlaswp01T</A>.
81

    
82
</BODY>
83
</HTML>