[llvm-commits] [test-suite] r47145 - /test-suite/trunk/RunSafely.sh

Lauro Ramos Venancio lauro.venancio at gmail.com
Thu Feb 14 15:46:20 PST 2008


Author: laurov
Date: Thu Feb 14 17:46:20 2008
New Revision: 47145

URL: http://llvm.org/viewvc/llvm-project?rev=47145&view=rev
Log:
Fix PR1437 and limit stack size.


Modified:
    test-suite/trunk/RunSafely.sh

Modified: test-suite/trunk/RunSafely.sh
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/RunSafely.sh?rev=47145&r1=47144&r2=47145&view=diff

==============================================================================
--- test-suite/trunk/RunSafely.sh (original)
+++ test-suite/trunk/RunSafely.sh Thu Feb 14 17:46:20 2008
@@ -81,6 +81,9 @@
     # To prevent infinite loops which fill up the disk, specify a limit on size of
     # files being output by the tests. 10 MB should be enough for anybody. ;)
     ULIMITCMD="$ULIMITCMD ulimit -f 10485760;"
+
+    # stack size: 100 MB should be enough for anybody. ;)
+    ULIMITCMD="$ULIMITCMD ulimit -s 100000;"
 esac
 rm -f core core.*
 
@@ -102,7 +105,7 @@
 fi
 
 if [ "x$RHOST" = x ] ; then
-  ( sh -c "$ULIMITCMD"; time -p sh -c "$COMMAND >$OUTFILE 2>&1 < $INFILE" ; echo exit $? ) 2>&1 \
+  ( sh -c "$ULIMITCMD time -p $COMMAND >$OUTFILE 2>&1 < $INFILE; echo exit \$?" ) 2>&1 \
     | awk -- '\
 BEGIN     { cpu = 0.0; }
 /^user/   { cpu += $2; print; }





More information about the llvm-commits mailing list