c6d234
The commit included in glibc-rh1372304-1.patch removes custom TIMEOUT
c6d234
definitions from the tests it changes. Some of those tests are expected to
c6d234
run for longer than the current default TIMEOUT (2 sec) set in
c6d234
test-skeleton.c and so can time-out and fail when run. This commit avoids
c6d234
the spurious failures by increasing the default TIMEOUT to 20 sec. Upstream,
c6d234
this commit preceded the one included in glibc-rh1372304-1.patch.
c6d234
c6d234
commit a28605b22946c708f0a5c4f06307e1a17650ced8
c6d234
Author: Mike Frysinger <vapier@gentoo.org>
c6d234
Date:   Tue Jan 19 09:18:00 2016 -0500
c6d234
c6d234
    test-skeleton: increase default TIMEOUT to 20 seconds
c6d234
    
c6d234
    The vast majority of timeouts I've seen w/glibc tests are due to:
c6d234
     - slow system (e.g. <1 GHz cpu)
c6d234
     - loaded system (e.g. lots of parallelism)
c6d234
    Even then, I've seen timeouts on system I don't generally consider
c6d234
    slow, or even loaded, and considering TIMEOUT is set to <=10 in ~60
c6d234
    tests (and <=20 in ~75 tests), it seems I'm not alone.  I've just
c6d234
    gotten in the habit of doing `export TIMEOUTFACTOR=10` on all my
c6d234
    setups.
c6d234
    
c6d234
    In the edge case where there is a bug in the test and the timeout is
c6d234
    hit, I think we all agree that's either a problem with the test or a
c6d234
    real bug in the library somewhere.  In either case, the incident rate
c6d234
    should be low, so catering to that seems like the wrong trade-off.
c6d234
    
c6d234
    Other developers too usually set large timeout factors.  Increase the
c6d234
    default to 20 seconds to match reality.
c6d234
c6d234
Index: b/test-skeleton.c
c6d234
===================================================================
c6d234
--- a/test-skeleton.c
c6d234
+++ b/test-skeleton.c
c6d234
@@ -368,8 +368,9 @@ main (int argc, char *argv[])
c6d234
 
c6d234
   /* Set timeout.  */
c6d234
 #ifndef TIMEOUT
c6d234
-  /* Default timeout is two seconds.  */
c6d234
-# define TIMEOUT 2
c6d234
+  /* Default timeout is twenty seconds.  Tests should normally complete faster
c6d234
+     than this, but if they don't, that's abnormal (a bug) anyways.  */
c6d234
+# define TIMEOUT 20
c6d234
 #endif
c6d234
   signal (SIGALRM, signal_handler);
c6d234
   alarm (TIMEOUT * timeoutfactor);