Changeset 347 for XIOS/trunk/src/server.cpp
- Timestamp:
- 05/21/12 17:57:22 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
XIOS/trunk/src/server.cpp
r346 r347 5 5 #include "context.hpp" 6 6 #include "object_template_impl.hpp" 7 #include "tree_manager.hpp"8 7 #include "oasis_cinterface.hpp" 9 8 #include <boost/functional/hash.hpp> 10 9 #include <boost/algorithm/string.hpp> 11 10 #include <mpi.h> 11 #include "tracer.hpp" 12 #include "timer.hpp" 12 13 13 14 namespace xios … … 132 133 else MPI_Finalize() ; 133 134 } 135 report(0)<<"Performance report : Time spent for XIOS : "<<CTimer::get("XIOS server").getCumulatedTime()<<endl ; 136 report(0)<<"Performance report : Time spent in processing events : "<<CTimer::get("Process events").getCumulatedTime()<<endl ; 137 report(0)<<"Performance report : Ratio : "<<CTimer::get("Process events").getCumulatedTime()/CTimer::get("XIOS server").getCumulatedTime()*100.<<"%"<<endl ; 134 138 } 135 139 … … 138 142 bool stop=false ; 139 143 144 CTimer::get("XIOS server").resume() ; 140 145 while(!stop) 141 146 { … … 154 159 if (finished && contextList.empty()) stop=true ; 155 160 } 156 161 CTimer::get("XIOS server").suspend() ; 157 162 } 158 163 … … 166 171 { 167 172 MPI_Status status ; 173 traceOff() ; 168 174 MPI_Iprobe(0,0,*it,&flag,&status) ; 175 traceOn() ; 169 176 if (flag==true) 170 177 { … … 199 206 int msg ; 200 207 208 traceOff() ; 201 209 MPI_Iprobe(0,4,intraComm, &flag, &status) ; 210 traceOn() ; 202 211 if (flag==true) 203 212 { … … 220 229 if (recept==false) 221 230 { 231 traceOff() ; 222 232 MPI_Iprobe(MPI_ANY_SOURCE,1,CXios::globalComm, &flag, &status) ; 233 traceOn() ; 223 234 if (flag==true) 224 235 { … … 232 243 else 233 244 { 245 traceOff() ; 234 246 MPI_Test(&request,&flag,&status) ; 247 traceOn() ; 235 248 if (flag==true) 236 249 { … … 304 317 if (recept==false) 305 318 { 319 traceOff() ; 306 320 MPI_Iprobe(root,2,intraComm, &flag, &status) ; 321 traceOn() ; 307 322 if (flag==true) 308 323 { … … 346 361 <<"Context has already been registred") ; 347 362 348 shared_ptr<CContext>context=CContext::create(contextId) ;349 contextList[contextId]=context .get();363 CContext* context=CContext::create(contextId) ; 364 contextList[contextId]=context ; 350 365 context->initServer(intraComm,contextIntercomm) ; 351 366
Note: See TracChangeset
for help on using the changeset viewer.