[powerpc64le-linux] libfaketime CLOCK_MONOTONIC test hangs

OpenSubmitted by Chris Marusich.
Details
One participant
  • Chris Marusich
Owner
unassigned
Severity
normal
C
C
Chris Marusich wrote 4 days ago
(address . bug-guix@gnu.org)
871r9atkne.fsf@gmail.com
Hi,
On powerpc64le-linux, using Guix commit7692295f970a292a3f3db31fc21d05efd97dcb25 on top of Debian unstable, thelibfaketime package fails to build because one of its tests hangs. Itappears to hang during the CLOCK_MONOTONIC test:
Toggle snippet (8 lines)Running the test program with no faked time specified$ LD_PRELOAD=../src/libfaketime.so.1 ./timetestpthread_cond_timedwait: CLOCK_REALTIME test(Intentionally sleeping 1 second...)pthread_cond_timedwait: CLOCK_MONOTONIC test(Intentionally sleeping 1 second..., see docs about CLOCK_MONOTONIC test)
There is no output after that last line. It just sits there. I left itthere for about 24 hours, and it didn't make any progress. I tried with--cores=1, too, but the problem still occurred. Therefore, it probablyisn't a multithreading issue.
On x86_64-linux Guix, using the aforementioned commit, on top of Fedora32, the tests pass and the libfaketime builds successfully. Therefore,this is probably a platform-specific issue.
The README file for libfaketime says:
Toggle quote (8 lines)> CLOCK_MONOTONIC test: Running "make test" performs a series of tests> after successful compilation of the libfaketime library. On some> platforms, the "CLOCK_MONOTONIC test" will apparently hang> forever. If and only if this happens on your platform, add the CFLAG> -DFORCE_MONOTONIC_FIX to src/Makefile and recompile libfaketime. Do> not set FORCE_MONOTONIC_FIX on platforms where the test does not> hang.
In fact, we do set this in Guix, via the (apparently undocumented)FAKETIME_COMPILE_CFLAGS environment variable:
Toggle snippet (19 lines)(define-public libfaketime (package (name "libfaketime") ... (arguments '(#:phases (modify-phases %standard-phases (replace 'configure (lambda* (#:key outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) (setenv "CC" "gcc") (setenv "PREFIX" out)
;; XXX: Without this flag, the CLOCK_REALTIME test hangs ;; indefinitely. See README.packagers for more information. ;; Try removing this for future versions of libfaketime. (setenv "FAKETIME_COMPILE_CFLAGS" "-DFORCE_MONOTONIC_FIX") ...
In spite of this, the test hangs on powerpc64le-linux. Out ofcuriosity, I tried NOT setting FAKETIME_COMPILE_CFLAGS, but the behaviorwas the same: it still got stuck forever on powerpc64le-linux.
-- Chris
-----BEGIN PGP SIGNATURE-----
iQJIBAEBCAAzFiEEy/WXVcvn5+/vGD+x3UCaFdgiRp0FAmDBkzUVHGNtbWFydXNpY2hAZ21haWwuY29tAAoJEN1AmhXYIkad5Q8P+O5nwDGGIaykQbkLx9iBNKpdUYL+53P7x6/OBOkcA8YhZcuXtVjYekYNVi97uXhqndVc9G/SB/gKWhioVa/KCcewq1Kd3hzQTOM5LZjuREc2GotEViNGYOhwPHqfwbOmQLlBptj3OmBjUlA7XUkUvlTk2oE9oYwYckPi9fLoRB6OdTQFqrTS1aOQvePEp0qJYOvoyRvrjDmsKdhkc2ny1HaG12kjQkY0EUvhX96FadKeilcjMmWNXt1AEvSa7Op2e0J4zwPHioiryCGHuCrCdViWgTndaY00vyvRbd+LNmXgBda1ZwjDZ8uzi+D1yAsNGlWmiyCR0aQL+ZqIqnbhwzyJ8m1OymHKBHf2njZM37HcOyAkjUwft++Ikcm4trLU3jynFRoevXFnf6xc8pMlELnp19YB64pi1kqxS9OU/alWEH4lkQNoBfQmH+FSSoELIyuN4t/VswouO2qXuv682tMKO+4Y21muJDBIJe4Bupp8gE+0ox+DgMHg3ck4wmfJeqSAUBkWJpDNJeGKnJpHaTPehNbYkFYiRqBoo62Ft9MOyjsujE8b5fDZF+njpNE+Hvf8IehWOtzpOA03YWW4ToD4C/vSVryYK8FEt9FH6q3l8hBFPkjrD3kdL9s2HyBxjP7OP1EewCEBwd1CGgQTRpdUPTLJfWFtWgLzeADkDeQ==75A5-----END PGP SIGNATURE-----
C
C
Chris Marusich wrote 2 days ago
(address . 48941@debbugs.gnu.org)
87wnqzssdz.fsf@gmail.com
Hi,
Since I'm not sure how to proceed, I've reported this upstream and askedfor help:
https://github.com/wolfcw/libfaketime/issues/335
-- Chris
-----BEGIN PGP SIGNATURE-----
iQJJBAEBCAAzFiEEy/WXVcvn5+/vGD+x3UCaFdgiRp0FAmDEIkgVHGNtbWFydXNpY2hAZ21haWwuY29tAAoJEN1AmhXYIkadNacP/1DrC2awRDnUCdPKj2QfVnWUqDq/M9P5++oDYTi/cVQLo7EyBb5OLaMajnO4hNhBrafqGTc6Q/udoji1X/7dJfxzdre0Uzzurk5qzyEPYDo7fw/gtx6Ok5UZ4Dc/zuOe4zBsBbAkw8yaD9ONnBRgXZl8AGaQmFPYtjr2+cCZHLOUWVV+9B3g5FLvnsjcX3IfKjzvCT9YF1Y0fEuwerHTrhBsQEJb6QVCLzqObThhjakAIlVozqVQFUbrp6o6hLPl1pT44Z5VuDWyIWBf1q73JonV5d3q1dKv3isuVYK8IhiAWV/dWM3lWt/PZ4X9rI4317zANthNATFBjOzfpCo9U2AGRW/OWM2G1FhfVET+1PUXAz5RxcGN9p2t/IQmMOBtBnB7dvARg6dNYEFnCowtL6BESOaooHkeFWB4oQPJMgb+j8Roa4KtjaCuFQ6z15Mk1ZdIP9iStHVjD1JGlXNQORkaXX3yOqzByvkUrfmYmzpthk77yTxHr8m1RG665VU4b4TOXfvEOjjqjR9Goz9a1RgETM6UXZasaL5wZguftXAAA7/GkptPO1mE5wZxRKw4cvKjlJ/vE4xnBpLJNMdGvOAjIqfTv0F9MtHcbfJgloRLAI+R9Y3k4A4+wgLUE+486pC50ySA9ZjGF/ffuSM85hbPJQwsYp1WZAp4X1TRxrOc=aG6a-----END PGP SIGNATURE-----
?