mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-06-04 18:54:00 +08:00
Use a more accurate timer to sleep on Linux systems.
This commit is contained in:
parent
4deafd35b7
commit
76fca22134
@ -53,8 +53,10 @@
|
|||||||
|
|
||||||
#if EIGEN_OS_WIN || EIGEN_OS_WIN64
|
#if EIGEN_OS_WIN || EIGEN_OS_WIN64
|
||||||
#define EIGEN_SLEEP(n) Sleep(n)
|
#define EIGEN_SLEEP(n) Sleep(n)
|
||||||
|
#elif EIGEN_OS_GNULINUX
|
||||||
|
#define EIGEN_SLEEP(n) usleep(n * 1000);
|
||||||
#else
|
#else
|
||||||
#define EIGEN_SLEEP(n) sleep(n*1000)
|
#define EIGEN_SLEEP(n) sleep(std::max<unsigned>(1, n/1000))
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user