OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
spmd_fvb_asub2.F File Reference
#include "implicit_f.inc"
#include "spmd.inc"
#include "task_c.inc"

Go to the source code of this file.

Functions/Subroutines

subroutine spmd_fvb_asub2 ()

Function/Subroutine Documentation

◆ spmd_fvb_asub2()

subroutine spmd_fvb_asub2

Definition at line 32 of file spmd_fvb_asub2.F.

33C-----------------------------------------------
34C M o d u l e s
35C-----------------------------------------------
36 USE fvbag_mod
37C-----------------------------------------------
38C I m p l i c i t T y p e s
39C-----------------------------------------------
40 USE spmd_comm_world_mod, ONLY : spmd_comm_world
41#include "implicit_f.inc"
42C-----------------------------------------------
43C M e s s a g e P a s s i n g
44C-----------------------------------------------
45#include "spmd.inc"
46C-----------------------------------------------
47C C o m m o n B l o c k s
48C-----------------------------------------------
49#include "task_c.inc"
50C-----------------------------------------------
51C L o c a l V a r i a b l e s
52C-----------------------------------------------
53#ifdef MPI
54 INTEGER I, PMAIN, J, ITAG, TAB(2), STAT(MPI_STATUS_SIZE), IERR,
55 . ID, NPOLH_ANIM, MSGOFF
56C-----------------------------------------------
57 DATA msgoff /7052/
58C-----------------------------------------------
59C
60 DO i=1,nfvbag
61 pmain=fvspmd(i)%PMAIN
62 IF (ispmd==0) THEN
63 IF (ispmd/=pmain-1) THEN
64 itag=msgoff
65 CALL mpi_recv(tab, 2, mpi_integer, it_spmd(pmain),
66 . itag, spmd_comm_world, stat, ierr)
67C
68 fvdata(i)%ID=tab(1)
69 fvdata(i)%NPOLH_ANIM=tab(2)
70 ENDIF
71 ELSE
72 IF (ispmd==pmain-1) THEN
73 tab(1)=fvdata(i)%ID
74 tab(2)=fvdata(i)%NPOLH_ANIM
75C
76 itag=msgoff
77 CALL mpi_send(tab, 2, mpi_integer, it_spmd(1),
78 . itag, spmd_comm_world, ierr)
79 ENDIF
80 ENDIF
81 ENDDO
82C
83#endif
84 RETURN
subroutine mpi_recv(buf, cnt, datatype, source, tag, comm, status, ierr)
Definition mpi.f:461
subroutine mpi_send(buf, cnt, datatype, dest, tag, comm, ierr)
Definition mpi.f:480
type(fvbag_spmd), dimension(:), allocatable fvspmd
Definition fvbag_mod.F:129
type(fvbag_data), dimension(:), allocatable fvdata
Definition fvbag_mod.F:128
integer nfvbag
Definition fvbag_mod.F:127