[Openmp-commits] [openmp] [openmp][AIX]Initial changes for porting to AIX (PR #76841)
Xing Xue via Openmp-commits
openmp-commits at lists.llvm.org
Thu Jan 4 08:49:15 PST 2024
================
@@ -62,6 +64,18 @@
#include <sys/sysctl.h>
#elif KMP_OS_SOLARIS
#include <sys/loadavg.h>
+#elif KMP_OS_AIX
+// These macros are not defined in AIX system headers.
+#define TIMEVAL_TO_TIMESPEC(tv, ts) \
+ { \
+ (ts)->tv_sec = (tv)->tv_sec; \
+ (ts)->tv_nsec = (tv)->tv_usec * 1000; \
+ }
+#define TIMESPEC_TO_TIMEVAL(tv, ts) \
+ { \
+ (tv)->tv_sec = (ts)->tv_sec; \
+ (tv)->tv_usec = (ts)->tv_nsec / 1000; \
+ }
----------------
xingxue-ibm wrote:
Good catch, thanks!
https://github.com/llvm/llvm-project/pull/76841
More information about the Openmp-commits
mailing list