X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=utils%2FNewNightlyTest.pl;h=447165fd613d735cfd92deea23395173e90c67b9;hb=180c1691c7fd79e2376bdd59e962d190607e20fa;hp=1a3adbca663bf45e97d890139d80c87dab1aa79c;hpb=849c9a28e184492515a10cf374c6ea1e8c3027a6;p=oota-llvm.git diff --git a/utils/NewNightlyTest.pl b/utils/NewNightlyTest.pl index 1a3adbca663..447165fd613 100755 --- a/utils/NewNightlyTest.pl +++ b/utils/NewNightlyTest.pl @@ -35,6 +35,7 @@ use Socket; # -disable-llc Disable LLC tests in the nightly tester. # -disable-jit Disable JIT tests in the nightly tester. # -disable-cbe Disable C backend tests in the nightly tester. +# -disable-lto Disable link time optimization. # -verbose Turn on some debug output # -debug Print information useful only to maintainers of this script. # -nice Checkout/Configure/Build with "nice" to reduce impact @@ -45,10 +46,8 @@ use Socket; # -gccpath Path to gcc/g++ used to build LLVM # -cvstag Check out a specific CVS tag to build LLVM (useful for # testing release branches) -# -usesvn Check code out from a subversion repository. With no -# argument, use the standard repository. An argument specifies -# the repository URL to use. -# -svnurl Specify the SVN URL where LLVM can be found +# -usecvs Check code out from the (old) CVS Repository instead of from +# the standard Subversion repository. # -target Specify the target triplet # -cflags Next argument specifies that C compilation options that # override the default. @@ -75,6 +74,7 @@ use Socket; # this option is not specified it defaults to # /nightlytest/NightlyTestAccept.php. This is basically # everything after the www.yourserver.org. +# -nosubmit Do not report the test results back to a submit server. # # CVSROOT is the CVS repository from which the tree will be checked out, # specified either in the full :method:user@host:/dir syntax, or @@ -96,7 +96,7 @@ use Socket; ############################################################## my $HOME = $ENV{'HOME'}; my $SVNURL = $ENV{"SVNURL"}; -$SVNURL = 'svn://anon@hlvm.org:3691/llvm.svn' unless $SVNURL; +$SVNURL = 'https://llvm.org/svn/llvm-project' unless $SVNURL; my $CVSRootDir = $ENV{'CVSROOT'}; $CVSRootDir = "/home/vadve/shared/PublicCVS" unless $CVSRootDir; my $BuildDir = $ENV{'BUILDDIR'}; @@ -122,11 +122,12 @@ my $TestStartTime = gmtime() . "GMT
" . localtime() . " (local)"; $CONFIGUREARGS=""; $nickname=""; $NOTEST=0; -$USESVN=0; +$USESVN=1; $NORUNNINGTESTS=0; $MAKECMD="make"; $SUBMITSERVER = "llvm.org"; $SUBMITSCRIPT = "/nightlytest/NightlyTestAccept.php"; +$SUBMIT = 1; while (scalar(@ARGV) and ($_ = $ARGV[0], /^[-+]/)) { shift; @@ -154,6 +155,8 @@ while (scalar(@ARGV) and ($_ = $ARGV[0], /^[-+]/)) { if (/^-disable-jit$/) { $PROGTESTOPTS .= " DISABLE_JIT=1"; $CONFIGUREARGS .= " --disable-jit"; next; } if (/^-disable-cbe$/) { $PROGTESTOPTS .= " DISABLE_CBE=1"; next; } + if (/^-disable-lto$/) { $PROGTESTOPTS .= " DISABLE_LTO=1"; next; } + if (/^-test-opts$/) { $PROGTESTOPTS .= " $ARGV[0]"; shift; next; } if (/^-verbose$/) { $VERBOSE = 1; next; } if (/^-debug$/) { $DEBUG = 1; next; } if (/^-nice$/) { $NICE = "nice "; next; } @@ -163,6 +166,7 @@ while (scalar(@ARGV) and ($_ = $ARGV[0], /^[-+]/)) { shift; next; } if (/^-submit-server/) { $SUBMITSERVER = "$ARGV[0]"; shift; next; } if (/^-submit-script/) { $SUBMITSCRIPT = "$ARGV[0]"; shift; next; } + if (/^-nosubmit$/) { $SUBMIT = 0; next; } if (/^-nickname$/) { $nickname = "$ARGV[0]"; shift; next; } if (/^-gccpath/) { $CONFIGUREARGS .= " CC=$ARGV[0]/gcc CXX=$ARGV[0]/g++"; @@ -170,8 +174,7 @@ while (scalar(@ARGV) and ($_ = $ARGV[0], /^[-+]/)) { else { $GCCPATH=""; } if (/^-cvstag/) { $CVSCOOPT .= " -r $ARGV[0]"; shift; next; } else { $CVSCOOPT="";} - if (/^-usesvn/) { $USESVN = 1; } - if (/^-svnurl/) { $SVNURL = $ARGV[0]; shift; next; } + if (/^-usecvs/) { $USESVN = 0; } if (/^-target/) { $CONFIGUREARGS .= " --target=$ARGV[0]"; shift; next; } if (/^-cflags/) { $MAKEOPTS = "$MAKEOPTS C.Flags=\'$ARGV[0]\'"; @@ -182,7 +185,6 @@ while (scalar(@ARGV) and ($_ = $ARGV[0], /^[-+]/)) { shift; next; } if (/^-compileflags/) { $MAKEOPTS = "$MAKEOPTS $ARGV[0]"; shift; next; } if (/^-use-gmake/) { $MAKECMD = "gmake"; shift; next; } - if (/^-compileflags/) { $MAKEOPTS = "$MAKEOPTS $ARGV[0]"; shift; next; } if (/^-extraflags/) { $CONFIGUREARGS .= " --with-extra-options=\'$ARGV[0]\'"; shift; next;} if (/^-noexternals$/) { $NOEXTERNALS = 1; next; } @@ -454,6 +456,7 @@ sub SendData{ $length = length($content); my $send= "POST $file HTTP/1.0\n"; + $send.= "Host: $host\n"; $send.= "Content-Type: application/x-www-form-urlencoded\n"; $send.= "Content-length: $length\n\n"; $send.= "$content"; @@ -514,24 +517,24 @@ ChangeDir( $BuildDir, "checkout directory" ); # ############################################################## if (!$NOCHECKOUT) { - if ( $VERBOSE ) { - print "CHECKOUT STAGE:\n"; - } + if ( $VERBOSE ) { print "CHECKOUT STAGE:\n"; } if ($USESVN) { my $SVNCMD = "$NICE svn co $SVNURL"; if ($VERBOSE) { print "( time -p $SVNCMD/llvm/trunk llvm; cd llvm/projects ; " . - "$SVNCMD/llvm-test/trunk llvm-test ) > $COLog 2>&1\n"; - system "( time -p $SVNCMD/llvm/trunk llvm; cd llvm/projects ; " . - "$SVNCMD/llvm-test/trunk llvm-test ) > $COLog 2>&1\n"; + "$SVNCMD/test-suite/trunk llvm-test ) > $COLog 2>&1\n"; } + system "( time -p $SVNCMD/llvm/trunk llvm; cd llvm/projects ; " . + "$SVNCMD/test-suite/trunk llvm-test ) > $COLog 2>&1\n"; } else { my $CVSOPT = ""; $CVSOPT = "-z3" # Use compression if going over ssh. if $CVSRootDir =~ /^:ext:/; my $CVSCMD = "$NICE cvs $CVSOPT -d $CVSRootDir co -P $CVSCOOPT"; - print "( time -p $CVSCMD llvm; cd llvm/projects ; " . - "$CVSCMD llvm-test ) > $COLog 2>&1\n"; + if ($VERBOSE) { + print "( time -p $CVSCMD llvm; cd llvm/projects ; " . + "$CVSCMD llvm-test ) > $COLog 2>&1\n"; + } system "( time -p $CVSCMD llvm; cd llvm/projects ; " . "$CVSCMD llvm-test ) > $COLog 2>&1\n"; } @@ -555,7 +558,7 @@ my $NumFilesInCVS = 0; my $NumDirsInCVS = 0; if ($USESVN) { $NumFilesInCVS = `egrep '^A' $COLog | wc -l` + 0; - $NumDirsInCVS = `sed -e 's#/[^/]*$##' $COLog | sort | uniq | wc -l` + 0; + $NumDirsInCVS = `sed -e 's#/[^/]*\$##' $COLog | sort | uniq | wc -l` + 0; } else { $NumFilesInCVS = `egrep '^U' $COLog | wc -l` + 0; $NumDirsInCVS = `egrep '^cvs (checkout|server|update):' $COLog | wc -l` + 0; @@ -740,7 +743,6 @@ $BuildWallTime=-1 unless $BuildWallTime; my $BuildError = 0, $BuildStatus = "OK"; if ($NOBUILD) { $BuildStatus = "Skipped by user"; - $BuildError = 1; } elsif (`grep '^$MAKECMD\[^:]*: .*Error' $BuildLog | wc -l` + 0 || `grep '^$MAKECMD: \*\*\*.*Stop.' $BuildLog | wc -l`+0) { @@ -1136,16 +1138,14 @@ my %hash_of_data = ( 'target_triple' => $targetTriple ); -$TESTING = 0; - -if ($TESTING) { +if ($SUBMIT) { + my $response = SendData $SUBMITSERVER,$SUBMITSCRIPT,\%hash_of_data; + if( $VERBOSE) { print "============================\n$response"; } +} else { print "============================\n"; foreach $x(keys %hash_of_data){ print "$x => $hash_of_data{$x}\n"; } -} else { - my $response = SendData $SUBMITSERVER,$SUBMITSCRIPT,\%hash_of_data; - if( $VERBOSE) { print "============================\n$response"; } } ##############################################################