19 # include "vt_unify_mpi.h"
23 # include "vt_unify_esync.h"
24 #endif // VT_ETIMESYNC
27 #include "vt_inttypes.h"
34 #if defined(HAVE_OMP) && HAVE_OMP
40 # else // VT_LIB || _SX
45 #define STRBUFSIZE 1024
51 # define MASTER if( MyRank == 0 )
52 # define SLAVE if( MyRank != 0 )
65 : verbose_level( 0 ), docompress( false ), doclean( true ),
66 showusage( false ), showversion( false ), showprogress( false ),
67 bequiet( false ), onlystats( false ), domsgmatch( false ),
68 droprecvs( false ), prof_sort_flags( 0x22 ), createthumb( false )
70 #if defined(HAVE_ZLIB) && HAVE_ZLIB
74 #ifdef VT_UNIFY_HOOKS_MSGMATCH
76 #endif // VT_UNIFY_HOOKS_MSGMATCH
78 #ifdef VT_UNIFY_HOOKS_THUMB
80 #endif // VT_UNIFY_HOOKS_THUMB
83 std::string in_file_prefix;
84 std::string out_file_prefix;
85 uint8_t verbose_level;
101 std::string prof_out_file;
117 : streamid( 0 ), pstreamid( 0 ), stream_avail(
true )
119 ltime[0] = ltime[1] = offset[0] = offset[1] = 0;
122 UnifyControlS(
const uint32_t & _streamid,
const uint32_t & _pstreamid,
123 const bool & _stream_avail,
const int64_t * _ltime,
124 const int64_t * _offset )
125 : streamid( _streamid ), pstreamid( _pstreamid ),
126 stream_avail( _stream_avail )
128 ltime[0] = _ltime[0]; ltime[1] = _ltime[1];
129 offset[0] = _offset[0]; offset[1] = _offset[1];
131 #else // VT_ETIMESYNC
133 : streamid( 0 ), pstreamid( 0 ), stream_avail(
true ), sync_offset( 0 ),
136 ltime[0] = ltime[1] = offset[0] = offset[1] = 0;
139 UnifyControlS(
const uint32_t & _streamid,
const uint32_t & _pstreamid,
140 const bool & _stream_avail,
const int64_t * _ltime,
141 const int64_t * _offset,
142 const std::vector<ETimeSyncC::SyncPhaseS> & _sync_phases,
143 const std::vector<ETimeSyncC::SyncTimeS> & _sync_times,
144 const std::vector<std::pair<uint32_t, uint32_t> > & _sync_pairs)
145 : streamid( _streamid ), pstreamid( _pstreamid ),
146 stream_avail( _stream_avail ), sync_offset( 0 ), sync_drift( 1.0 ),
147 sync_phases( _sync_phases ), sync_times( _sync_times ),
148 sync_pairs( _sync_pairs )
150 ltime[0] = _ltime[0]; ltime[1] = _ltime[1];
151 offset[0] = _offset[0]; offset[1] = _offset[1];
153 #endif // VT_ETIMESYNC
164 uint64_t sync_offset;
166 std::vector<ETimeSyncC::SyncPhaseS> sync_phases;
167 std::vector<ETimeSyncC::SyncTimeS> sync_times;
168 std::vector<std::pair<uint32_t, uint32_t> > sync_pairs;
169 #endif // VT_ETIMESYNC
174 void VPrint( uint8_t level,
const char * fmt, ... );
177 void PVPrint( uint8_t level,
const char * fmt, ... );
180 bool SyncError(
bool * error );
186 extern const std::string ExeName;
189 extern const std::string TmpFileSuffix;
192 extern const std::string UniFilePrefix;
198 extern std::vector<UnifyControlS*> UnifyCtls;
201 extern std::map<uint32_t, UnifyControlS*> StreamId2UnifyCtl;
204 extern std::vector<uint32_t> MyStreamIds;
208 extern VT_MPI_INT NumRanks;
211 extern VT_MPI_INT MyRank;
214 extern std::map<uint32_t, VT_MPI_INT> StreamId2Rank;
217 extern std::map<VT_MPI_INT, std::set<uint32_t> > Rank2StreamIds;
220 #endif // _VT_UNIFY_H_
Definition: datastructs.h:41
Definition: vt_unify.h:113