13 #ifndef _VT_UNIFY_USRCOM_H_
14 #define _VT_UNIFY_USRCOM_H_
18 #include "vt_inttypes.h"
37 : comm( 0 ), tag( 0 ) {}
38 ComIdS(
const uint32_t & _comm,
const uint32_t & _tag )
39 : comm( _comm ), tag( _tag ) {}
42 bool operator<(
const ComIdS & a )
const
62 : sender( 0 ), receiver( 0 ) {}
63 ComPairS(
const uint32_t & _sender,
const uint32_t & _receiver )
64 : sender( _sender ), receiver( _receiver ) {}
77 void addUserComm(
const uint32_t & comm )
79 m_userComms.insert( comm );
83 bool isUserComm(
const uint32_t & comm )
const
85 return ( m_userComms.find( comm ) != m_userComms.end() );
89 bool addSender(
const ComIdS & comId,
const uint32_t & sender );
92 bool addReceiver(
const ComIdS & comId,
const uint32_t & receiver );
95 uint32_t getSender(
const uint32_t & comm,
const uint32_t & tag )
const
99 std::map<ComIdS, ComPairS>::const_iterator it =
100 m_comId2ComPair.find( ComIdS( comm, tag ) );
101 if( it != m_comId2ComPair.end() )
102 sender = it->second.sender;
108 uint32_t getReceiver(
const uint32_t & comm,
const uint32_t & tag )
const
110 uint32_t receiver = 0;
112 std::map<ComIdS, ComPairS>::const_iterator it =
113 m_comId2ComPair.find( ComIdS( comm, tag ) );
114 if( it != m_comId2ComPair.end() )
115 receiver = it->second.receiver;
128 std::set<uint32_t> m_userComms;
131 std::map<ComIdS, ComPairS> m_comId2ComPair;
138 #endif // _VT_UNIFY_USRCOM_H_
VampirTrace http://www.tu-dresden.de/zih/vampirtrace.
Definition: vt_unify_usrcom.h:26
Definition: vt_unify_usrcom.h:33
Definition: vt_unify_usrcom.h:58