X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Frts%2Fposix%2FGetTime.c;h=3a0764cb91cf5094ef672630aee6f7b351323ce7;hb=acc7c96112e6554461ec6704f27fe4ae3fa7aae2;hp=a5fcb21e918ff977c49abb7d071919ff6f605d83;hpb=6aa27c7233e8905e9f296020d6d0ff95795f1d39;p=ghc-hetmet.git diff --git a/ghc/rts/posix/GetTime.c b/ghc/rts/posix/GetTime.c index a5fcb21..3a0764c 100644 --- a/ghc/rts/posix/GetTime.c +++ b/ghc/rts/posix/GetTime.c @@ -6,7 +6,9 @@ * * ---------------------------------------------------------------------------*/ -#include "PosixSource.h" +// Not POSIX, due to use of ru_majflt in getPageFaults() +// #include "PosixSource.h" + #include "Rts.h" #include "GetTime.h" @@ -113,7 +115,7 @@ void getProcessTimes(Ticks *user, Ticks *elapsed) Ticks getThreadCPUTime(void) { -#ifdef HAVE_CLOCK_GETTIME +#if defined(HAVE_CLOCK_GETTIME) && defined(CLOCK_THREAD_CPUTIME_ID) // clock_gettime() gives us per-thread CPU time. It isn't // reliable on Linux, but it's the best we have. struct timespec ts;