In 30_threads/future/members/poll.c, despite the calibration and the
large tolerance, wait_until_sys_min has occasionally come up to almost
320 times as long as ready.  Tolerate that much measurement noise.

Tested with gcc-14 targeting ppc-vx7r2 and ppc64-vx7r2.  Also tested
with trunk on ppc64le-linux-gnu, and with gcc-14 targeting powerpc-elf.
Ok to install?


for  libstdc++-v3/ChangeLog

        * testsuite/30_threads/future/members/poll.cc (main): Increase
        tolerance for measurement noise.
---
 .../testsuite/30_threads/future/members/poll.cc    |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/libstdc++-v3/testsuite/30_threads/future/members/poll.cc 
b/libstdc++-v3/testsuite/30_threads/future/members/poll.cc
index 2113cfde70d60..cffe4a331da71 100644
--- a/libstdc++-v3/testsuite/30_threads/future/members/poll.cc
+++ b/libstdc++-v3/testsuite/30_threads/future/members/poll.cc
@@ -154,13 +154,13 @@ int main()
 
   // Polling before ready using wait_until(min) should not be terribly
   // slow.  We hope for no more than 100x slower, but a little over
-  // 100x has been observed, and since the measurements may have a lot
+  // 316x has been observed, and since the measurements may have a lot
   // of noise, and increasing the measurement precision through
   // additional iterations would make the test run for too long on
   // systems with very low clock precision (60Hz clocks are not
   // unheard of), we tolerate a lot of error.
-  VERIFY( wait_until_sys_min < (ready * 200) );
-  VERIFY( wait_until_steady_min < (ready * 200) );
+  VERIFY( wait_until_sys_min < (ready * 320) );
+  VERIFY( wait_until_steady_min < (ready * 320) );
 
   // The following two tests fail with GCC 11, see
   // https://gcc.gnu.org/pipermail/libstdc++/2020-November/051422.html

-- 
Alexandre Oliva, happy hacker            https://blog.lx.oliva.nom.br/
Free Software Activist     FSFLA co-founder     GNU Toolchain Engineer
More tolerance and less prejudice are key for inclusion and diversity.
Excluding neuro-others for not behaving ""normal"" is *not* inclusive!

Reply via email to