Ignore:
Timestamp:
11/15/17 12:14:34 (6 years ago)
Author:
yushan
Message:

dev_omp

Location:
XIOS/dev/branch_openmp/src/test
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/branch_openmp/src/test/test_client.f90

    r1134 r1328  
    3535 
    3636  CALL MPI_INIT(ierr) 
     37 
    3738  CALL init_wait 
    38  
    39   CALL MPI_COMM_RANK(MPI_COMM_WORLD,rank,ierr) 
    40   if(rank < 2) then 
    4139 
    4240!!! XIOS Initialization (get the local communicator) 
     
    7472 
    7573  CALL xios_context_initialize("test",comm) 
    76  
    7774  CALL xios_get_handle("test",ctx_hdl) 
    7875  CALL xios_set_current_context(ctx_hdl) 
     
    128125  CALL xios_is_defined_field_attr("field_A",enabled=ok) 
    129126  PRINT *,"field_A : attribute enabled is defined ? ",ok 
    130    
    131127  CALL xios_close_context_definition() 
    132128 
    133129  PRINT*,"field field_A is active ? ",xios_field_is_active("field_A") 
    134  
    135   call MPI_Barrier(comm, ierr) 
    136  
    137130  DO ts=1,24*10 
    138131    CALL xios_update_calendar(ts) 
    139132    CALL xios_send_field("field_A",field_A) 
    140     CALL wait_us(5000) 
     133    CALL wait_us(5000) ; 
    141134  ENDDO 
    142135 
     
    148141 
    149142  CALL xios_finalize() 
    150   print *, "Client : xios_finalize " 
    151  
    152     else 
    153  
    154     CALL xios_init_server 
    155     print *, "Server : xios_finalize " 
    156    
    157     endif 
    158      
    159143 
    160144  CALL MPI_FINALIZE(ierr) 
  • XIOS/dev/branch_openmp/src/test/test_complete.f90

    r1134 r1328  
    55  IMPLICIT NONE 
    66  INCLUDE "mpif.h" 
    7   INTEGER :: rank, size 
     7  INTEGER :: rank 
    88  INTEGER :: size_loc 
    99  INTEGER :: ierr 
     
    2828  INTEGER, ALLOCATABLE :: kindex(:) 
    2929  INTEGER :: ni,ibegin,iend,nj,jbegin,jend 
    30   INTEGER :: i,j,l,ts,n, nb_pt, provided 
     30  INTEGER :: i,j,l,ts,n, nb_pt 
    3131 
    3232!!! MPI Initialization 
    3333 
    34   CALL MPI_INIT_THREAD(3, provided, ierr) 
    35     if(provided .NE. 3) then 
    36       print*, "provided thread level = ", provided 
    37       call MPI_Abort() 
    38     endif  
    39  
    40    
     34  CALL MPI_INIT(ierr) 
    4135 
    4236  CALL init_wait 
    43  
    44   CALL MPI_COMM_RANK(MPI_COMM_WORLD,rank,ierr) 
    45   CALL MPI_COMM_SIZE(MPI_COMM_WORLD,size,ierr) 
    46   if(rank < size-1) then 
    4737 
    4838!!! XIOS Initialization (get the local communicator) 
     
    230220!#################################################################################### 
    231221 
    232     DO ts=1,24*2 
    233     !DO ts=1,24 
     222    DO ts=1,24*10 
    234223 
    235224      CALL xios_get_handle("atmosphere",ctx_hdl) 
     
    266255!!! Fin des contextes 
    267256 
    268  
    269     CALL xios_get_handle("surface",ctx_hdl)  
    270  
     257    CALL xios_context_finalize() 
     258    CALL xios_get_handle("atmosphere",ctx_hdl) 
    271259    CALL xios_set_current_context(ctx_hdl) 
    272260    CALL xios_context_finalize() 
    273261 
    274     print *, "xios_context_finalize(surface)"  
    275  
    276      CALL xios_get_handle("atmosphere",ctx_hdl) 
    277  
    278      CALL xios_set_current_context(ctx_hdl) 
    279  
    280      CALL xios_context_finalize() 
    281  
    282      print *, "xios_context_finalize(atmosphere)" 
    283  
    284      
    285  
    286 !!! Fin de XIOS 
    287  
    288      
    289  
    290     CALL xios_finalize() 
    291  
    292262    DEALLOCATE(lon, lat, field_A_atm, lonvalue) 
    293263    DEALLOCATE(kindex, field_A_srf) 
    294264 
    295      print *, "Client : xios_finalize " 
     265!!! Fin de XIOS 
    296266 
    297267    CALL MPI_COMM_FREE(comm, ierr) 
    298268 
    299   else 
    300  
    301     CALL xios_init_server 
    302     print *, "Server : xios_finalize " 
    303    
    304     endif 
    305  
     269    CALL xios_finalize() 
    306270 
    307271    CALL MPI_FINALIZE(ierr) 
  • XIOS/dev/branch_openmp/src/test/test_remap.f90

    r1141 r1328  
    4242  CALL MPI_INIT(ierr) 
    4343  CALL init_wait 
    44    
    45   CALL MPI_COMM_RANK(MPI_COMM_WORLD,rank,ierr) 
    46   CALL MPI_COMM_SIZE(MPI_COMM_WORLD,size,ierr) 
    47   if(rank < size-2) then 
    4844 
    4945!!! XIOS Initialization (get the local communicator) 
     
    232228 
    233229  CALL xios_finalize() 
    234    
    235   print *, "Client : xios_finalize " 
    236  
    237     else 
    238  
    239     CALL xios_init_server 
    240     print *, "Server : xios_finalize " 
    241    
    242     endif 
    243230 
    244231  CALL MPI_FINALIZE(ierr) 
Note: See TracChangeset for help on using the changeset viewer.