Skip to content

Patch to use 64-bit clock_* function on archs like armhf

Pushkar Kulkarni requested to merge pushkarnk/openjdk:armhf-t64-patch into openjdk-11

We have moved to using 64-bit time_t (time64_t) on armhf. In os_posix.cpp, we use clock_gettime() to calculate the absolute time (struct timespec) to be sent to pthread_cond_timed_wait(). The clock_gettime and cloc_getres symbols are linked using dlsym(). On archs like armhf, which now use 64-bit time_t, passing the latter to 32-bit clock_gettime corrupts the returned timespec, causing the pthread_cond_timedwait to error out. To avoid these errors use __clock_gettime64() and __clock_getres64() explicitly.

Merge request reports

Loading