Changeset 1665 for XIOS/dev/dev_trunk_omp/src/test/test_omp.f90
- Timestamp:
- 05/20/19 13:14:51 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
XIOS/dev/dev_trunk_omp/src/test/test_omp.f90
r1646 r1665 33 33 INTEGER :: i,j,l,ts,n, provided 34 34 35 integer :: num_args, ix, nb_servers 36 character(len=12), dimension(:), allocatable :: args 37 38 num_args = command_argument_count() 39 if(num_args<1) then 40 print*, "please give the number of servers as input argument." 41 call abort 42 endif 43 44 allocate(args(num_args)) ! I've omitted checking the return status of the allocation 45 46 do ix = 1, num_args 47 call get_command_argument(ix,args(ix)) 48 ! now parse the argument as you wish 49 end do 50 51 READ(args(1),*) nb_servers 52 35 53 !!! MPI Initialization 36 54 … … 45 63 CALL MPI_COMM_RANK(MPI_COMM_WORLD,rank,ierr) 46 64 CALL MPI_COMM_SIZE(MPI_COMM_WORLD,size,ierr) 47 if(rank < size- 4) then65 if(rank < size-nb_servers) then 48 66 49 67 !$omp parallel default(firstprivate)
Note: See TracChangeset
for help on using the changeset viewer.