https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63400
Jonathan Wakely <redi at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Target| |mingw-w64 --- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> --- Which of macros are defined on mingw-w64? Preprocessing this should tell you #include <chrono> #ifdef _GLIBCXX_USE_CLOCK_REALTIME #ifdef _GLIBCXX_USE_CLOCK_GETTIME_SYSCALL #warning system_clock using syscall(SYS_clock_gettime, CLOCK_REALTIME, &tp); #else #warning system_clock using clock_gettime(CLOCK_REALTIME, &tp); #endif #elif defined(_GLIBCXX_USE_GETTIMEOFDAY) #warning system_clock using gettimeofday(&tv, 0); #else #warning system_clock using std::time(0); #endif #ifdef _GLIBCXX_USE_CLOCK_MONOTONIC #ifdef _GLIBCXX_USE_CLOCK_GETTIME_SYSCALL #warning steady_clock using syscall(SYS_clock_gettime, CLOCK_MONOTONIC, &tp); #else #warning steady_clock using clock_gettime(CLOCK_MONOTONIC, &tp); #endif #else #warning steady_clock using time_point(system_clock::now().time_since_epoch()); #endif