Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
% LaTeX document
\documentclass[a4paper,12pt]{article}
\usepackage[koi8-r]{inputenc}
\usepackage[russian]{babel}
\begin{document}
\begin{titlepage}
\begin{center}
\Huge{\textbf{
\\
\\
INM~ParLib ( 1.0)}}
\vspace{0.1\textheight}
\Large{~.~.} \\
\vspace{0.2\textheight}
\Large{ ~ \\
, \today}
\end{center}
\end{titlepage}
\section{}
INM ParLib, ~\cite{T126} ~\cite{AGCM} .
, , , .
.
.
.
, , .
, , .
, .
~\cite{Ilghiz}, \cite{Swarztrauber} , ~\cite{Barros}.
, , ( , ).
\section{ }
, , .
\subsection{ }
MPI , MPI.
, {\tt -I{\it \_\_\-\-}/include}, ~-- {\tt -L{\it \_\_}/lib -lparlib}, a {\tt -lparlibf}.
\subsection{ }
\begin{verbatim}
INCLUDE 'parlibf.h'
\end{verbatim}
,
\begin{verbatim}
#include 'parlib.h'
\end{verbatim}
.
\subsubsection{ }
$\cal A$ .
().
, .
\begin{verbatim}
DIMENSION A(STRIDE(1), ..., STRIDE(NDIMS))
\end{verbatim}
{\tt NDIMS}~-- , {\tt STRIDE}~-- .
, {\tt BDIM}~-- , $\cal A$ , , .
\\{\tt P\_BExchange} :
\begin{verbatim}
CALL P_BEXCAHNGE (ARR, NDIMS, STRIDE, BLKLEN, BDIM,
1 OVERLAP, DATATYPE, COMM, PERIOD, IERROR)
\end{verbatim}
{\tt ARR}~-- {\tt A}; {\tt BLKLEN}~-- {\tt A}, , , {\tt ARR(1:BLKLEN(1), ..., 1:BLKLEN(NDIMS))}.
{\tt OVERLAP}, {\tt OVERLAP(1)} {\tt BDIM}, ~-- {\tt OVERLAP(2)}.
{\tt PERIOD} .
, .
MPI {\tt COMM}, {\tt A} MPI {\tt DATATYPE}.
, {\tt MPI\_REAL} {\tt MPI\_DOUBLE\_PRECISION}.
% ,
.
:
\begin{verbatim}
CALL P_BEXCAHNGE_INIT (NDIMS, STRIDE, BLKLEN, BDIM,
1 OVERLAP, DATATYPE, COMM, PERIO, BEXCHANGE, IERROR)
CALL P_BEXCAHNGE_START (ARR, BEXCHANGE, IERROR)
CALL P_BEXCAHNGE_END (BEXCHANGE, IERROR)
CALL P_BEXCAHNGE_FREE (BEXCHANGE, IERROR)
\end{verbatim}
, , , {\tt BEXCHANGE}, , , , , , .
, {\tt P\_BExcahnge\_start} {\tt P\_BExchange\_end} , .
\subsubsection{}
, $\cal A$ {\tt DIM\_SOURCE} {\tt LBLKS\_SOURCE(IPROC)}, {\tt IPROC}~-- , {\tt DIM\_DEST} .
$\cal A$ , {\tt LBLKS\_DEST(IPROC)} {\tt DIM\_DEST} {\tt DIM\_SOURCE}.
{\tt ARR\_SOURCE}~-- $\cal A$ , {\tt ARR\_DEST}~-- , :
\begin{verbatim}
CALL P_TRANSPOSE (NDIMS, ARR_SOURCE, DIM_SOURCE,
1 LBLKS_SOURCE, ARR_DEST, DIM_DEST, LBLKS_DEST,
2 STRIDE, BLKLEN, OVERLAP, DATATYPE, COMM, PERIOD,
3 DIAG, IERROR)
\end{verbatim}
{\tt NDIMS}~-- $\cal A$, {\tt DATATYPE}~-- MPI, , {\tt COMM}~-- MPI, .
, $\cal A$ , .
, , {\tt DIAG} {\tt .FALSE.} .
$\cal A$ {\tt A\_SOURCE}, ~-- {\tt A\_DEST}.
\begin{verbatim}
DIMENSION A_SOURCE(DIM_SOURCE(1), ..., DIM_SOURCE(NDIMS))
DIMENSION A_DEST(DIM_DEST(1), ..., DIM_DEST(NDIMS))
\end{verbatim}
{\tt DIM\_SOURCE} :
$$
\texttt{DIM\_SOURSE(IDIM)}=\left\{
\begin{array}{l}
\texttt{BLKLEN(DIM\_SOURCE)} \textrm{, } \texttt{IDIM=DIM\_SOURCE}\\
\texttt{STRIDE(IDIM)} \textrm{, }
\end{array}\right.
$$
{\tt DIM\_DEST}:
$$
\texttt{DIM\_DEST(IDIM)}=\left\{
\begin{array}{l}
\texttt{BLKLEN(DIM\_DEST)} \textrm{, } \texttt{IDIM=DIM\_DEST}\\
\texttt{STRIDE(IDIM)} \textrm{, }
\end{array}\right.
$$
{\tt A\_SOURCE} {\tt A\_DEST} , :
\begin{verbatim}
ARR_SOURCE(1:BLK_SOURCE(1), ..., 1:BLK_SOURCE(NDIMS)
ARR_DEST(1:BLK_DEST(1), ..., 1:BLK_DEST(NDIMS)
\end{verbatim}
:
$$
\texttt{BLK\_SOURCE(IDIM)}=\left\{
\begin{array}{l}
\texttt{LBLKS\_SOURCE(IPROC)} \textrm{, } \texttt{IDIM=DIM\_SOURCE} \\
\sum\texttt{LBLKS\_DEST} \textrm{, } \texttt{IDIM=DIM\_DEST} \\
\texttt{BLKLEN(IDIM)} \textrm{, }
\end{array}\right.
$$
$$
\texttt{BLK\_DEST(IDIM)}=\left\{
\begin{array}{l}
\texttt{LBLKS\_DEST(IPROC)} \textrm{, } \texttt{IDIM=DIM\_DEST} \\
\sum\texttt{LBLKS\_SOURE} \textrm{, } \texttt{IDIM=DIM\_SOURCE} \\
\texttt{BLKLEN(IDIM)} \textrm{, }
\end{array}\right.
$$
:
\begin{verbatim}
CALL P_TRANSPOSE_INIT (NDIMS, DIM_SOURCE, LBLKS_SOURCE,
1 DIM_DEST, LBLKS_DEST, STRIDE, BLKLEN, OVERLAP, DATATYPE,
2 COMM, PERIOD, DIAG, TRANSP, IERROR)
CALL P_TRANSPOSE_START (ARR_SOURCE, ARR_DEST, TRANSP,
1 IERROR)
CALL P_TRANSPOSE_END (TRANSP, IERROR)
CALL P_TRANSPOSE_FREE (TRANSP, IERROR)
\end{verbatim}
{\tt TRANSP}~-- .
\begin{thebibliography}{}
\bibitem{T126} ~.~. T126 . Optimization of Finite Element Approximations, Splines and Wavelets (OFEA'2001). Abstracts of International conference (June~25--29, 2001, St.-Petersburg, Russia), 2001, 184~p.
\bibitem{AGCM} .~A.~Tolstykh, V.~N.~Gloukhov. Implementation of global atmospheric models on parallel computers. {\it .} ~, .
\bibitem{Ilghiz} ~.~. . . , , 1999.
\bibitem{Swarztrauber} P.~N.~Swarztrauber, S.~W.~Hammond. A comparison of optimal FFTs on torus and hypercube multicomputers. {\it Parallel computing},~27 (2001), pp.~847--859.
\bibitem{Barros} Barros,~S.~R.~M., Kauranne,~T. On the parallelization of global spectral weather models. {\it Parallel Computing},~20 (1994), pp.~1335--1356.
\bibitem{Rodriguez} B.~Rodriguez, L.~Hart, T.~Henderson. Performance and portability in parallel computing: a weather forecasr view. {\it High Performance Computing in the Geosciences}, 1995, Kluwer Academic Publishers, Netherlands, pp.~1--23.
\bibitem{Henderson} T.~Henderson, D.~Shaffer, M.~Govett, L.~Hart. SMS User's Guide. Advanced Computing Branch, Aviation Division, NOAA Forecast system laboratory, Boulder, 2001.
\end{thebibliography}
\end{document}