Changeset 1745 for XIOS


Ignore:
Timestamp:
10/17/19 10:22:09 (5 years ago)
Author:
yushan
Message:

Generic_testcase: build flag --omp to enable EP with intelmpi. --omp2 to enable EP with openmpi. tested on Irene with compiler=intel17, mpi=intelmpi&openmpi, with and without EP

Location:
XIOS/dev/dev_trunk_omp
Files:
18 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/job_irene.sh

    r1743 r1745  
    7979make report 
    8080 
     81echo "Generic testcase report" | mailx -s "report" -a report.html yushan.wang@lsce.ipsl.fr 
    8182 
    8283rm -f test_*/setup.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/job_jz.sh

    r1743 r1745  
    6464make report 
    6565 
     66echo "Generic testcase report" | mailx -s "report" -a report.html yushan.wang@lsce.ipsl.fr 
    6667 
    6768rm -f test_*/setup.py 
  • XIOS/dev/dev_trunk_omp/GENERIC_TESTCASE/run_sub_test.sh

    r1743 r1745  
    2525then 
    2626    echo "Testing on Irene" 
     27    echo "build_dir="$build_dir 
    2728    ccc_mprun -n $nb_proc $xios_dir/$build_dir/bin/generic_testcase.exe 
    2829elif [[($machine_name == ada)]] 
  • XIOS/dev/dev_trunk_omp/bld.cfg

    r1679 r1745  
    7272bld::tool::ld        %LINKER 
    7373bld::tool::ldflags   %LD_FLAGS  
    74 bld::tool::cflags    %CFLAGS %CBASE_INC -I${PWD}/extern/src_netcdf -I${PWD}/extern/boost/include -I${PWD}/extern/rapidxml/include -I${PWD}/extern/blitz/include -I${PWD}/extern/src_ep_dev  
     74bld::tool::cflags    %CFLAGS %CBASE_INC -I${PWD}/extern/src_netcdf -I${PWD}/extern/boost/include -I${PWD}/extern/rapidxml/include -I${PWD}/extern/blitz/include -I${PWD}/extern/src_ep_dev 
    7575bld::tool::fflags    %FFLAGS %FBASE_INC  
    7676bld::tool::cppkeys   %CPP_KEY 
  • XIOS/dev/dev_trunk_omp/extern/src_ep_dev/ep_lib.cpp

    r1646 r1745  
    138138       || datatype == MPI_LONG  
    139139       || datatype == MPI_UNSIGNED_LONG 
    140        || datatype == MPI_LONG_LONG) 
     140       || datatype == MPI_LONG_LONG_INT) 
    141141    { 
    142142      return true; 
    143143    } 
    144144 
     145    //std::cout<<"datatype="<<datatype<<",int="<<MPI_INT<<",float="<<MPI_FLOAT<<",double="<<MPI_DOUBLE<<",char="<<MPI_CHAR<<",long="<<MPI_LONG<<",u_char="<<MPI_UNSIGNED_CHAR<<",l_long="<<MPI_LONG_LONG<<std::endl; 
    145146    return false; 
    146147  } 
  • XIOS/dev/dev_trunk_omp/extern/src_ep_dev/ep_reduce.cpp

    r1646 r1745  
    343343 
    344344#endif 
     345 
     346 
  • XIOS/dev/dev_trunk_omp/inputs/iodef.xml

    r1691 r1745  
    1717 
    1818 
    19     <file_definition type="multiple_file" par_access="collective" output_freq="1h" output_level="10" >  
     19    <file_definition type="one_file" par_access="collective" output_freq="2h" output_level="10" >  
    2020       
    2121     <file id="output2" name="output2" output_freq="4h" enabled=".FALSE."> 
     
    3737        <!-- <field field_ref="field_C" name="field_C_name"  enabled=".TRUE." />  --> 
    3838        <!-- <field id="field_D" field_ref="field_A" operation="instant" build_workflow_graph=".TRUE." name="field_D_name" build_workflow_graph_start="1h" build_workflow_graph_end="2h" > sqrt(field_A) </field> --> 
    39         <field id="field_E" field_ref="field_A" operation="instant" build_workflow_graph=".TRUE." name="field_E_name" build_workflow_graph_start="1h" build_workflow_graph_end="4h" > field_A + field_B + field_C</field> 
     39        <field id="field_D" field_ref="field_A" operation="average" build_workflow_graph=".TRUE." name="field_D" > field_A + field_B + field_C</field> 
    4040        <!-- <field field_ref="field_A_zoom" name="field_B" build_workflow_graph=".TRUE."/> --> 
    4141     </file> 
     
    8888        <variable_group id="buffer"> 
    8989            <variable id="optimal_buffer_size" type="string">performance</variable> 
    90             <variable id="buffer_size_factor" type="double">10.0</variable> 
     90            <variable id="buffer_size_factor" type="double">1.5</variable>  
    9191         </variable_group> 
    9292 
    9393        <variable_group id="parameters" > 
    9494          <variable id="using_server" type="bool">false</variable> 
    95           <variable id="info_level" type="int">80</variable> 
     95          <variable id="info_level" type="int">100</variable> 
    9696          <variable id="print_file" type="bool">true</variable> 
    9797        </variable_group> 
  • XIOS/dev/dev_trunk_omp/inputs/job.sh

    r1605 r1745  
    1818#cp $HOME/dev/dev_yushan/bin/xios_server.exe ./ 
    1919 
    20 ccc_mprun ../bin/test_omp.exe 
     20ccc_mprun ../../build_prod/bin/test_omp.exe 
    2121#ccc_mprun ./EP_test 
    2222#ddt -start -n 4 ./EP_test 
  • XIOS/dev/dev_trunk_omp/inputs/job_irene_openmpi.sh

    r1744 r1745  
    77#MSUB -e client_error.err    #error output 
    88#MSUB -eo 
    9 #MSUB -c 2  
     9#MSUB -c 1  
    1010#MSUB -n 8  # Number of MPI tasks (SPMD case) or cores (MPMD case) 
    1111#MSUB -X  
  • XIOS/dev/dev_trunk_omp/make_xios

    r1665 r1745  
    1919arch_path_defined="FALSE" 
    2020use_ep="FALSE" 
     21use_ep2="FALSE" 
    2122# Traitement de la ligne de commande 
    2223while (($# > 0)) 
     
    6566         "--memtrack")  use_memtrack="true" memtrack=$2  ; shift ; shift ;; 
    6667         "--omp")   use_ep="true" ; shift ;; 
     68         "--omp2")   use_ep2="true" ; shift ;; 
    6769         *)         code="$1"           ; shift ;; 
    6870      esac 
     
    162164if [[ "$use_ep" == "true" ]]; then 
    163165 
    164 if [[ "$compil_mode" == "prod" ]] 
    165    then 
    166       COMPIL_CFLAGS="%PROD_CFLAGS -D_usingEP -D_intelmpi" 
    167       COMPIL_FFLAGS="%PROD_FFLAGS -D_usingEP -D_intelmpi" 
    168 elif [[ "$compil_mode" == "dev" ]] 
    169    then  
    170       COMPIL_CFLAGS="%DEV_CFLAGS -D_usingEP -D_intelmpi" 
    171       COMPIL_FFLAGS="%DEV_FFLAGS -D_usingEP -D_intelmpi" 
    172 elif [[ "$compil_mode" == "debug" ]] 
    173    then 
    174       COMPIL_CFLAGS="%DEBUG_CFLAGS -D_usingEP -D_intelmpi" 
    175       COMPIL_FFLAGS="%DEBUG_FFLAGS -D_usingEP -D_intelmpi" 
    176 fi 
    177  
    178 else 
    179  
    180 if [[ "$compil_mode" == "prod" ]] 
    181    then 
    182       COMPIL_CFLAGS="%PROD_CFLAGS" 
    183       COMPIL_FFLAGS="%PROD_FFLAGS" 
    184 elif [[ "$compil_mode" == "dev" ]] 
    185    then  
    186       COMPIL_CFLAGS="%DEV_CFLAGS" 
    187       COMPIL_FFLAGS="%DEV_FFLAGS" 
    188 elif [[ "$compil_mode" == "debug" ]] 
    189    then 
    190       COMPIL_CFLAGS="%DEBUG_CFLAGS" 
    191       COMPIL_FFLAGS="%DEBUG_FFLAGS" 
    192 fi 
    193  
    194 fi 
     166    if [[ "$compil_mode" == "prod" ]] 
     167        then 
     168        COMPIL_CFLAGS="%PROD_CFLAGS -D_usingEP -D_intelmpi" 
     169        COMPIL_FFLAGS="%PROD_FFLAGS -D_usingEP -D_intelmpi" 
     170    elif [[ "$compil_mode" == "dev" ]] 
     171        then  
     172        COMPIL_CFLAGS="%DEV_CFLAGS -D_usingEP -D_intelmpi" 
     173        COMPIL_FFLAGS="%DEV_FFLAGS -D_usingEP -D_intelmpi" 
     174    elif [[ "$compil_mode" == "debug" ]] 
     175        then 
     176        COMPIL_CFLAGS="%DEBUG_CFLAGS -D_usingEP -D_intelmpi" 
     177        COMPIL_FFLAGS="%DEBUG_FFLAGS -D_usingEP -D_intelmpi" 
     178    fi 
     179 
     180else 
     181 
     182    if [[ "$compil_mode" == "prod" ]] 
     183        then 
     184        COMPIL_CFLAGS="%PROD_CFLAGS" 
     185        COMPIL_FFLAGS="%PROD_FFLAGS" 
     186    elif [[ "$compil_mode" == "dev" ]] 
     187        then  
     188        COMPIL_CFLAGS="%DEV_CFLAGS" 
     189        COMPIL_FFLAGS="%DEV_FFLAGS" 
     190    elif [[ "$compil_mode" == "debug" ]] 
     191        then 
     192        COMPIL_CFLAGS="%DEBUG_CFLAGS" 
     193        COMPIL_FFLAGS="%DEBUG_FFLAGS" 
     194    fi 
     195 
     196fi 
     197 
     198 
     199 
     200if [[ "$use_ep2" == "true" ]]; then 
     201 
     202    if [[ "$compil_mode" == "prod" ]] 
     203        then 
     204        COMPIL_CFLAGS="%PROD_CFLAGS -D_usingEP -D_openmpi" 
     205        COMPIL_FFLAGS="%PROD_FFLAGS -D_usingEP -D_openmpi" 
     206    elif [[ "$compil_mode" == "dev" ]] 
     207        then  
     208        COMPIL_CFLAGS="%DEV_CFLAGS -D_usingEP -D_openmpi" 
     209        COMPIL_FFLAGS="%DEV_FFLAGS -D_usingEP -D_openmpi" 
     210    elif [[ "$compil_mode" == "debug" ]] 
     211        then 
     212        COMPIL_CFLAGS="%DEBUG_CFLAGS -D_usingEP -D_openmpi" 
     213        COMPIL_FFLAGS="%DEBUG_FFLAGS -D_usingEP -D_openmpi" 
     214    fi 
     215 
     216else 
     217 
     218    if [[ "$compil_mode" == "prod" ]] 
     219        then 
     220        COMPIL_CFLAGS="%PROD_CFLAGS" 
     221        COMPIL_FFLAGS="%PROD_FFLAGS" 
     222    elif [[ "$compil_mode" == "dev" ]] 
     223        then  
     224        COMPIL_CFLAGS="%DEV_CFLAGS" 
     225        COMPIL_FFLAGS="%DEV_FFLAGS" 
     226    elif [[ "$compil_mode" == "debug" ]] 
     227        then 
     228        COMPIL_CFLAGS="%DEBUG_CFLAGS" 
     229        COMPIL_FFLAGS="%DEBUG_FFLAGS" 
     230    fi 
     231 
     232fi 
     233 
     234 
     235 
    195236rm -r $PWD/extern/netcdf4 
    196237 
     
    321362 
    322363exit $build_exit_status 
     364 
     365 
  • XIOS/dev/dev_trunk_omp/src/context_server.cpp

    r1665 r1745  
    8383 
    8484    traceOff(); 
     85    #ifdef _usingEP 
    8586    MPI_Iprobe(-2, 20,interComm,&flag,&status); 
     87    #else     
     88    MPI_Iprobe(MPI_ANY_SOURCE, 20,interComm,&flag,&status); 
     89    #endif 
    8690    traceOn(); 
    8791 
  • XIOS/dev/dev_trunk_omp/src/event_scheduler.cpp

    r1646 r1745  
    139139    while(received) 
    140140    { 
     141      #ifdef _usingEP  
    141142      MPI_Iprobe(-2,1,communicator,&received, &status) ; 
     143      #else       
     144      MPI_Iprobe(MPI_ANY_SOURCE,1,communicator,&received, &status) ; 
     145      #endif 
    142146      if (received) 
    143147      { 
    144148        recvRequest=new SPendingRequest ; 
     149        #ifdef _usingEP 
    145150        MPI_Irecv(recvRequest->buffer, 3, MPI_UNSIGNED_LONG, -2, 1, communicator, &(recvRequest->request)) ; 
     151        #else 
     152        MPI_Irecv(recvRequest->buffer, 3, MPI_UNSIGNED_LONG, MPI_ANY_SOURCE, 1, communicator, &(recvRequest->request)) ; 
     153        #endif 
    146154        pendingRecvParentRequest.push(recvRequest) ; 
    147155      } 
     
    181189    while(received) 
    182190    { 
     191      #ifdef _usingEP 
    183192      MPI_Iprobe(-2,0,communicator,&received, &status) ; 
     193      #else 
     194      MPI_Iprobe(MPI_ANY_SOURCE,0,communicator,&received, &status) ; 
     195      #endif 
    184196      if (received) 
    185197      { 
    186198        recvRequest=new SPendingRequest ; 
     199        #ifdef _usingEP 
    187200        MPI_Irecv(recvRequest->buffer, 3, MPI_UNSIGNED_LONG, -2, 0, communicator, &recvRequest->request) ; 
     201        #else 
     202        MPI_Irecv(recvRequest->buffer, 3, MPI_UNSIGNED_LONG, MPI_ANY_SOURCE, 0, communicator, &recvRequest->request) ; 
     203        #endif 
    188204        pendingRecvChildRequest.push_back(recvRequest) ; 
    189205      } 
  • XIOS/dev/dev_trunk_omp/src/interface/c/oasis_cinterface.cpp

    r1650 r1745  
    2222    fxios_oasis_enddef() ; 
    2323  } 
    24  
     24#ifdef _usingEP 
    2525  void oasis_get_localcomm(MPI_Comm& comm) 
    2626  { 
     
    4646    //comm_client_server=MPI_Comm_f2c(f_comm) ; 
    4747  } 
     48 
     49#else 
     50 
     51  void oasis_get_localcomm(MPI_Comm& comm) 
     52  { 
     53    MPI_Fint f_comm ; 
     54     
     55    fxios_oasis_get_localcomm(&f_comm) ; 
     56    //comm=MPI_Comm_f2c(f_comm) ; 
     57  } 
     58  
     59  void oasis_get_intracomm(MPI_Comm& comm_client_server,const std::string& server_id) 
     60  { 
     61    MPI_Fint f_comm ; 
     62     
     63    fxios_oasis_get_intracomm(&f_comm,server_id.data(),server_id.size()) ; 
     64    //comm_client_server=MPI_Comm_f2c(f_comm) ; 
     65  } 
     66  
     67  void oasis_get_intercomm(MPI_Comm& comm_client_server,const std::string& server_id) 
     68  { 
     69    MPI_Fint f_comm ; 
     70     
     71    fxios_oasis_get_intercomm(&f_comm,server_id.data(),server_id.size()) ; 
     72    //comm_client_server=MPI_Comm_f2c(f_comm) ; 
     73  } 
     74 
     75 
     76 
     77#endif 
    4878} 
  • XIOS/dev/dev_trunk_omp/src/interface/c/oasis_cinterface.hpp

    r1650 r1745  
    1010  void fxios_oasis_enddef(void) ; 
    1111  void fxios_oasis_finalize(void) ; 
     12#ifdef _usingEP 
    1213  void fxios_oasis_get_localcomm(ep_lib::EP_Fint* f_comm) ; 
    1314  void fxios_oasis_get_intracomm(ep_lib::EP_Fint* f_comm_client_server,const char* client_id,int str_len) ; 
    1415  void fxios_oasis_get_intercomm(ep_lib::EP_Fint* f_comm_client_server,const char* client_id,int str_len) ; 
     16#else 
     17  void fxios_oasis_get_localcomm(MPI_Fint* f_comm) ; 
     18  void fxios_oasis_get_intracomm(MPI_Fint* f_comm_client_server,const char* client_id,int str_len) ; 
     19  void fxios_oasis_get_intercomm(MPI_Fint* f_comm_client_server,const char* client_id,int str_len) ; 
     20#endif 
    1521} 
    1622  
     
    2329  void oasis_get_intracomm(ep_lib::MPI_Comm& comm_client_server,const std::string& server_id) ; 
    2430  void oasis_get_intercomm(ep_lib::MPI_Comm& comm_client_server,const std::string& server_id) ; 
     31 
    2532} 
    2633#endif 
  • XIOS/dev/dev_trunk_omp/src/parse_expr/yacc_parser.cpp

    r1680 r1745  
    9696    yacc_globalInputText_ptr = globalInputText_ptr; 
    9797 
    98     std::cout<<"========= yacc_globalInputText_ptr = "<<*yacc_globalInputText_ptr<<std::endl; 
    9998    if(globalInputText_ptr == 0) globalInputText_ptr = new std::string; 
    10099    size_t numBytesToRead = maxBytesToRead; 
  • XIOS/dev/dev_trunk_omp/src/server.cpp

    r1665 r1745  
    662662       { 
    663663         traceOff() ; 
     664         #ifdef _usingEP 
    664665         MPI_Iprobe(-2,1,CXios::globalComm, &flag, &status) ; 
     666         #else 
     667         MPI_Iprobe(MPI_ANY_SOURCE,1,CXios::globalComm, &flag, &status) ; 
     668         #endif 
    665669         traceOn() ; 
    666670         if (flag==true) 
  • XIOS/dev/dev_trunk_omp/src/test/test_omp.f90

    r1681 r1745  
    5454 
    5555    CALL MPI_INIT_THREAD(3, provided, ierr) 
    56     if(provided .NE. 3) then 
     56!    if(provided .NE. 3) then 
    5757      print*, "provided thread level = ", provided 
    58       call MPI_Abort() 
    59     endif 
     58!      call MPI_Abort() 
     59!    endif 
    6060 
    6161    CALL init_wait 
  • XIOS/dev/dev_trunk_omp/src/transformation/domain_algorithm_interpolate.cpp

    r1677 r1745  
    695695  { 
    696696    ep_lib::MPI_Status recvStatus; 
     697    #ifdef _usingEP 
    697698    MPI_Recv((recvIndexDestBuff + receivedSize), 
    698699             recvBuffSize, 
     
    702703             client->intraComm, 
    703704             &recvStatus); 
    704  
     705    #else 
     706    MPI_Recv((recvIndexDestBuff + receivedSize), 
     707             recvBuffSize, 
     708             MPI_INT, 
     709             MPI_ANY_SOURCE, 
     710             MPI_DOMAIN_INTERPOLATION_DEST_INDEX, 
     711             client->intraComm, 
     712             &recvStatus); 
     713   
     714 
     715    #endif 
    705716    int countBuff = 0; 
    706717    ep_lib::MPI_Get_count(&recvStatus, MPI_INT, &countBuff); 
Note: See TracChangeset for help on using the changeset viewer.