Ignore:
Timestamp:
02/20/12 11:22:02 (12 years ago)
Author:
ymipsl
Message:

Removing obsolete files and some cleaning...

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/trunk/src/client_ym.cpp

    r300 r314  
    44#include <boost/functional/hash.hpp> 
    55#include "type.hpp" 
    6 #include "buffer.hpp" 
    76#include "context.hpp" 
    87#include "context_client.hpp" 
     
    130129     
    131130     
    132      
    133      
    134 /*     
    135     void CClient::initialize(const string& codeId,MPI_Comm& localComm,MPI_Comm& returnComm) 
    136     { 
    137       boost::hash<string> hashString ;     
    138      
    139       unsigned long hashClient=hashString(codeId) ; 
    140       unsigned long hashServer=hashString(CXios::xiosCodeId) ; 
    141       unsigned long* hashAll ; 
    142       int rank ; 
    143       int size ; 
    144       int myColor ; 
    145       int i,c ; 
    146       MPI_Comm newComm ; 
    147        
    148       MPI_Comm_size(CXios::globalComm,&size) ; 
    149       MPI_Comm_rank(CXios::globalComm,&rank); 
    150       hashAll=new unsigned long[size] ; 
    151       
    152       MPI_Allgather(&hashClient,1,MPI_LONG,hashAll,1,MPI_LONG,CXios::globalComm) ; 
    153  
    154       map<unsigned long, int> colors ; 
    155       map<unsigned long, int> leaders ; 
    156        
    157       for(i=0,c=0;i<size;i++) 
    158       { 
    159         if (colors.find(hashAll[i])==colors.end()) 
    160         { 
    161           colors[hashAll[i]] =c ; 
    162           leaders[hashAll[i]]=i ; 
    163           c++ ; 
    164         } 
    165          
    166       } 
    167       
    168       myColor=colors[hashClient] ; 
    169        
    170       MPI_Comm_split(CXios::globalComm,myColor,rank,&intraComm) ; 
    171  
    172       if (!CXios::isServer) 
    173       {      
    174         int clientLeader=leaders[hashClient] ; 
    175         serverLeader=leaders[hashServer] ; 
    176         MPI_Intercomm_create(intraComm,0,CXios::globalComm,serverLeader,0,&interComm) ; 
    177       } 
    178       else 
    179       { 
    180         MPI_Comm_dup(intraComm,&interComm) ; 
    181       } 
    182  
    183       delete [] hashAll ; 
    184     } 
    185   */ 
    186      
    187131    void CClient::registerContext(const string& id,MPI_Comm contextComm) 
    188132    { 
Note: See TracChangeset for help on using the changeset viewer.