Ignore:
Timestamp:
09/09/22 17:23:16 (22 months ago)
Author:
ymipsl
Message:

-Fix performance issue in one_sided protocol

  • better timer instrumentation of the protocol

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS3/trunk/src/transport/one_sided_context_client.cpp

    r2343 r2399  
    9696        } 
    9797        itBuffer->second->eventLoop() ; 
     98        double time=CTimer::getTime() ; 
    9899        bool succed = itBuffer->second->writeEvent(timeLine, event)  ; 
     100        if (succed)  
     101        { 
     102          time=CTimer::getTime()-time ; 
     103          if (!CTimer::get("Blocking time").isSuspended()) CTimer::get("Blocking time").minus(time) ; 
     104        } 
     105 
    99106        if (succed) event.remove() ; 
    100107        else event.next() ; 
    101         if (event.isFirst()) callGlobalEventLoop() ; 
    102       } 
    103        
     108        if (event.isFirst()) 
     109        { 
     110          if (CTimer::get("Blocking time").isSuspended()) CTimer::get("Blocking time").resume() ; 
     111          callGlobalEventLoop() ; 
     112        }  
     113      } 
     114      if (!CTimer::get("Blocking time").isSuspended()) CTimer::get("Blocking time").suspend() ; 
     115 
    104116      if (isAttachedModeEnabled()) // couldBuffer is always true in attached mode 
    105117      { 
Note: See TracChangeset for help on using the changeset viewer.