mirror of
https://github.com/moses-smt/mosesdecoder.git
synced 2025-01-02 17:09:36 +03:00
15 lines
379 B
C++
15 lines
379 B
C++
|
#ifndef UTIL_STREAM_TIMER__
|
||
|
#define UTIL_STREAM_TIMER__
|
||
|
|
||
|
#include <boost/version.hpp>
|
||
|
|
||
|
#if BOOST_VERSION >= 104800
|
||
|
#include <boost/timer/timer.hpp>
|
||
|
#define UTIL_TIMER(str) boost::timer::auto_cpu_timer timer(std::cerr, 1, (str))
|
||
|
#else
|
||
|
//#warning Using Boost older than 1.48. Timing information will not be available.
|
||
|
#define UTIL_TIMER(str)
|
||
|
#endif
|
||
|
|
||
|
#endif // UTIL_STREAM_TIMER__
|