33 subroutine mpp_transmit_scalar_( put_data, to_pe, get_data, from_pe, plen, glen, block, tag, &
34 recv_request, send_request)
35 integer,
intent(in) :: to_pe, from_pe
36 mpp_type_,
intent(in) :: put_data
37 mpp_type_,
intent(out) :: get_data
38 integer,
optional,
intent(in) :: plen, glen
39 logical,
intent(in),
optional :: block
40 integer,
intent(in),
optional :: tag
41 integer,
intent(out),
optional :: recv_request, send_request
42 integer :: put_len, get_len
43 mpp_type_ :: put_data1d(1), get_data1d(1)
44 pointer( ptrp, put_data1d )
45 pointer( ptrg, get_data1d )
47 get_data = mpp_type_init_value
51 put_len=1;
if(
PRESENT(plen))put_len=plen
52 get_len=1;
if(
PRESENT(glen))get_len=glen
53 call mpp_transmit_ ( put_data1d, put_len, to_pe, get_data1d, get_len, from_pe, block, tag, &
54 recv_request=recv_request, send_request=send_request )
57 end subroutine mpp_transmit_scalar_
59 subroutine mpp_transmit_2d_( put_data, put_len, to_pe, get_data, get_len, from_pe, block, tag, &
60 recv_request, send_request )
61 integer,
intent(in) :: put_len, to_pe, get_len, from_pe
62 mpp_type_,
intent(in) :: put_data(:,:)
63 mpp_type_,
intent(out) :: get_data(:,:)
64 logical,
intent(in),
optional :: block
65 integer,
intent(in),
optional :: tag
66 integer,
intent(out),
optional :: recv_request, send_request
67 mpp_type_ :: put_data1d(put_len), get_data1d(get_len)
69 pointer( ptrp, put_data1d )
70 pointer( ptrg, get_data1d )
71 get_data = mpp_type_init_value
75 call mpp_transmit( put_data1d, put_len, to_pe, get_data1d, get_len, from_pe, block, tag, &
76 recv_request=recv_request, send_request=send_request )
79 end subroutine mpp_transmit_2d_
81 subroutine mpp_transmit_3d_( put_data, put_len, to_pe, get_data, get_len, from_pe, block, tag, &
82 recv_request, send_request )
83 integer,
intent(in) :: put_len, to_pe, get_len, from_pe
84 mpp_type_,
intent(in) :: put_data(:,:,:)
85 mpp_type_,
intent(out) :: get_data(:,:,:)
86 logical,
intent(in),
optional :: block
87 integer,
intent(in),
optional :: tag
88 integer,
intent(out),
optional :: recv_request, send_request
89 mpp_type_ :: put_data1d(put_len), get_data1d(get_len)
91 pointer( ptrp, put_data1d )
92 pointer( ptrg, get_data1d )
93 get_data = mpp_type_init_value
97 call mpp_transmit( put_data1d, put_len, to_pe, get_data1d, get_len, from_pe, block, tag, &
98 recv_request=recv_request, send_request=send_request )
101 end subroutine mpp_transmit_3d_
103 subroutine mpp_transmit_4d_( put_data, put_len, to_pe, get_data, get_len, from_pe, block, tag, &
104 recv_request, send_request )
105 integer,
intent(in) :: put_len, to_pe, get_len, from_pe
106 mpp_type_,
intent(in) :: put_data(:,:,:,:)
107 mpp_type_,
intent(out) :: get_data(:,:,:,:)
108 logical,
intent(in),
optional :: block
109 integer,
intent(in),
optional :: tag
110 integer,
intent(out),
optional :: recv_request, send_request
111 mpp_type_ :: put_data1d(put_len), get_data1d(get_len)
113 pointer( ptrp, put_data1d )
114 pointer( ptrg, get_data1d )
115 get_data = mpp_type_init_value
119 call mpp_transmit( put_data1d, put_len, to_pe, get_data1d, get_len, from_pe, block, tag, &
120 recv_request=recv_request, send_request=send_request )
123 end subroutine mpp_transmit_4d_
125 subroutine mpp_transmit_5d_( put_data, put_len, to_pe, get_data, get_len, from_pe, block, tag, &
126 recv_request, send_request )
127 integer,
intent(in) :: put_len, to_pe, get_len, from_pe
128 mpp_type_,
intent(in) :: put_data(:,:,:,:,:)
129 mpp_type_,
intent(out) :: get_data(:,:,:,:,:)
130 logical,
intent(in),
optional :: block
131 integer,
intent(in),
optional :: tag
132 integer,
intent(out),
optional :: recv_request, send_request
133 mpp_type_ :: put_data1d(put_len), get_data1d(get_len)
135 pointer( ptrp, put_data1d )
136 pointer( ptrg, get_data1d )
137 get_data = mpp_type_init_value
141 call mpp_transmit( put_data1d, put_len, to_pe, get_data1d, get_len, from_pe, block, tag, &
142 recv_request=recv_request, send_request=send_request )
145 end subroutine mpp_transmit_5d_
152 subroutine mpp_recv_( get_data, get_len, from_pe, block, tag, request )
154 integer,
intent(in) :: get_len, from_pe
155 mpp_type_,
intent(out) :: get_data(*)
156 logical,
intent(in),
optional :: block
157 integer,
intent(in),
optional :: tag
158 integer,
intent(out),
optional :: request
160 mpp_type_ :: dummy(1)
161 call mpp_transmit( dummy, 1, null_pe, get_data, get_len, from_pe, block, tag, recv_request=request )
162 end subroutine mpp_recv_
164 subroutine mpp_send_( put_data, put_len, to_pe, tag, request )
166 integer,
intent(in) :: put_len, to_pe
167 mpp_type_,
intent(in) :: put_data(*)
168 integer,
intent(in),
optional :: tag
169 integer,
intent(out),
optional :: request
170 mpp_type_ :: dummy(1)
171 call mpp_transmit( put_data, put_len, to_pe, dummy, 1, null_pe, tag=tag, send_request=request )
172 end subroutine mpp_send_
174 subroutine mpp_recv_scalar_( get_data, from_pe, glen, block, tag, request )
176 integer,
intent(in) :: from_pe
177 mpp_type_,
intent(out) :: get_data
178 logical,
intent(in),
optional :: block
179 integer,
intent(in),
optional :: tag
180 integer,
intent(out),
optional :: request
182 integer,
optional,
intent(in) :: glen
184 mpp_type_ :: get_data1d(1)
185 mpp_type_ :: dummy(1)
187 pointer( ptr, get_data1d )
188 get_data = mpp_type_init_value
191 get_len=1;
if(
PRESENT(glen))get_len=glen
192 call mpp_transmit( dummy, 1, null_pe, get_data1d, get_len, from_pe, block, tag, recv_request=request )
194 end subroutine mpp_recv_scalar_
196 subroutine mpp_send_scalar_( put_data, to_pe, plen, tag, request)
198 integer,
intent(in) :: to_pe
199 mpp_type_,
intent(in) :: put_data
200 integer,
optional,
intent(in) :: plen
201 integer,
intent(in),
optional :: tag
202 integer,
intent(out),
optional :: request
204 mpp_type_ :: put_data1d(1)
205 mpp_type_ :: dummy(1)
207 pointer( ptr, put_data1d )
209 put_len=1;
if(
PRESENT(plen))put_len=plen
210 call mpp_transmit( put_data1d, put_len, to_pe, dummy, 1, null_pe, tag = tag, send_request=request )
212 end subroutine mpp_send_scalar_
214 subroutine mpp_recv_2d_( get_data, get_len, from_pe, block, tag, request )
216 integer,
intent(in) :: get_len, from_pe
217 mpp_type_,
intent(out) :: get_data(:,:)
218 logical,
intent(in),
optional :: block
219 integer,
intent(in),
optional :: tag
220 integer,
intent(out),
optional :: request
222 mpp_type_ :: dummy(1,1)
223 call mpp_transmit( dummy, 1, null_pe, get_data, get_len, from_pe, block, tag, recv_request=request )
224 end subroutine mpp_recv_2d_
226 subroutine mpp_send_2d_( put_data, put_len, to_pe, tag, request )
228 integer,
intent(in) :: put_len, to_pe
229 mpp_type_,
intent(in) :: put_data(:,:)
230 integer,
intent(in),
optional :: tag
231 integer,
intent(out),
optional :: request
232 mpp_type_ :: dummy(1,1)
233 call mpp_transmit( put_data, put_len, to_pe, dummy, 1, null_pe, tag = tag, send_request=request )
234 end subroutine mpp_send_2d_
236 subroutine mpp_recv_3d_( get_data, get_len, from_pe, block, tag, request )
238 integer,
intent(in) :: get_len, from_pe
239 mpp_type_,
intent(out) :: get_data(:,:,:)
240 logical,
intent(in),
optional :: block
241 integer,
intent(in),
optional :: tag
242 integer,
intent(out),
optional :: request
244 mpp_type_ :: dummy(1,1,1)
245 call mpp_transmit( dummy, 1, null_pe, get_data, get_len, from_pe, block, tag, recv_request=request )
246 end subroutine mpp_recv_3d_
248 subroutine mpp_send_3d_( put_data, put_len, to_pe, tag, request )
250 integer,
intent(in) :: put_len, to_pe
251 mpp_type_,
intent(in) :: put_data(:,:,:)
252 integer,
intent(in),
optional :: tag
253 integer,
intent(out),
optional :: request
254 mpp_type_ :: dummy(1,1,1)
255 call mpp_transmit( put_data, put_len, to_pe, dummy, 1, null_pe, tag = tag, send_request=request )
256 end subroutine mpp_send_3d_
258 subroutine mpp_recv_4d_( get_data, get_len, from_pe, block, tag, request )
260 integer,
intent(in) :: get_len, from_pe
261 mpp_type_,
intent(out) :: get_data(:,:,:,:)
262 logical,
intent(in),
optional :: block
263 integer,
intent(in),
optional :: tag
264 integer,
intent(out),
optional :: request
266 mpp_type_ :: dummy(1,1,1,1)
267 call mpp_transmit( dummy, 1, null_pe, get_data, get_len, from_pe, block, tag, recv_request=request )
268 end subroutine mpp_recv_4d_
270 subroutine mpp_send_4d_( put_data, put_len, to_pe, tag, request )
272 integer,
intent(in) :: put_len, to_pe
273 mpp_type_,
intent(in) :: put_data(:,:,:,:)
274 integer,
intent(in),
optional :: tag
275 integer,
intent(out),
optional :: request
276 mpp_type_ :: dummy(1,1,1,1)
277 call mpp_transmit( put_data, put_len, to_pe, dummy, 1, null_pe, tag = tag, send_request=request )
278 end subroutine mpp_send_4d_
280 subroutine mpp_recv_5d_( get_data, get_len, from_pe, block, tag, request)
282 integer,
intent(in) :: get_len, from_pe
283 mpp_type_,
intent(out) :: get_data(:,:,:,:,:)
284 logical,
intent(in),
optional :: block
285 integer,
intent(in),
optional :: tag
286 integer,
intent(out),
optional :: request
288 mpp_type_ :: dummy(1,1,1,1,1)
289 call mpp_transmit( dummy, 1, null_pe, get_data, get_len, from_pe, block, tag, recv_request=request )
290 end subroutine mpp_recv_5d_
292 subroutine mpp_send_5d_( put_data, put_len, to_pe, tag, request )
294 integer,
intent(in) :: put_len, to_pe
295 mpp_type_,
intent(in) :: put_data(:,:,:,:,:)
296 integer,
intent(in),
optional :: tag
297 integer,
intent(out),
optional :: request
298 mpp_type_ :: dummy(1,1,1,1,1)
299 call mpp_transmit( put_data, put_len, to_pe, dummy, 1, null_pe, tag = tag, send_request=request )
300 end subroutine mpp_send_5d_
308 subroutine mpp_broadcast_scalar_( broadcast_data, from_pe, pelist )
309 mpp_type_,
intent(inout) :: broadcast_data
310 integer,
intent(in) :: from_pe
311 integer,
intent(in),
optional :: pelist(:)
312 mpp_type_ :: data1d(1)
314 pointer( ptr, data1d )
316 ptr = loc(broadcast_data)
317 call mpp_broadcast_( data1d, 1, from_pe, pelist )
320 end subroutine mpp_broadcast_scalar_
322 subroutine mpp_broadcast_2d_( broadcast_data, length, from_pe, pelist )
326 mpp_type_,
intent(inout) :: broadcast_data(:,:)
327 integer,
intent(in) :: length, from_pe
328 integer,
intent(in),
optional :: pelist(:)
329 mpp_type_ :: data1d(length)
331 pointer( ptr, data1d )
332 ptr = loc(broadcast_data)
333 call mpp_broadcast( data1d, length, from_pe, pelist )
336 end subroutine mpp_broadcast_2d_
338 subroutine mpp_broadcast_3d_( broadcast_data, length, from_pe, pelist )
342 mpp_type_,
intent(inout) :: broadcast_data(:,:,:)
343 integer,
intent(in) :: length, from_pe
344 integer,
intent(in),
optional :: pelist(:)
345 mpp_type_ :: data1d(length)
347 pointer( ptr, data1d )
348 ptr = loc(broadcast_data)
349 call mpp_broadcast( data1d, length, from_pe, pelist )
352 end subroutine mpp_broadcast_3d_
354 subroutine mpp_broadcast_4d_( broadcast_data, length, from_pe, pelist )
358 mpp_type_,
intent(inout) :: broadcast_data(:,:,:,:)
359 integer,
intent(in) :: length, from_pe
360 integer,
intent(in),
optional :: pelist(:)
361 mpp_type_ :: data1d(length)
363 pointer( ptr, data1d )
364 ptr = loc(broadcast_data)
365 call mpp_broadcast( data1d, length, from_pe, pelist )
368 end subroutine mpp_broadcast_4d_
370 subroutine mpp_broadcast_5d_( broadcast_data, length, from_pe, pelist )
374 mpp_type_,
intent(inout) :: broadcast_data(:,:,:,:,:)
375 integer,
intent(in) :: length, from_pe
376 integer,
intent(in),
optional :: pelist(:)
377 mpp_type_ :: data1d(length)
379 pointer( ptr, data1d )
380 ptr = loc(broadcast_data)
381 call mpp_broadcast( data1d, length, from_pe, pelist )
384 end subroutine mpp_broadcast_5d_