Hello!

Trivial tsan testcase check (tsan_init in lib/tsan-dg.exp) does not
terminate properly on CentOS 5.10. Instead of waiting for the default
of 300 seconds, attached patch limits total execution time to 20
seconds.

2014-02-04  Uros Bizjak  <ubiz...@gmail.com>

    * lib/tsan-dg.exp (tsan_init): Set trivial testcase timeout value to 20s.

Tested on x86_64-pc-linux-gnu (CentOS 5.10) with RUNTESTFLAGS=tsan.exp

OK for mainline?

Uros.
Index: lib/tsan-dg.exp
===================================================================
--- lib/tsan-dg.exp     (revision 207452)
+++ lib/tsan-dg.exp     (working copy)
@@ -98,6 +98,10 @@
        }
     }
     if { $link_flags != "" } {
+       global individual_timeout
+
+       # Lower timeout value in case test does not terminate properly.
+       set individual_timeout 20
        if [check_runtime_nocache tsan_works {
                int main () { return 0; }
            } "-fPIE -pie -fsanitize=thread -g"] {
@@ -105,13 +109,14 @@
        } else {
            set dg-do-what-default compile
        }
+       unset individual_timeout
        return 1
     }
     return 0
 }
 
 #
-# tsan_finish -- called at the start of each subdir of tests
+# tsan_finish -- called at the end of each subdir of tests
 #
 
 proc tsan_finish { args } {

Reply via email to