SPARC NCG: Add Pwr callish mach op
[ghc-hetmet.git] / utils / runstdtest / runstdtest.prl
index 385a9fb..039c253 100644 (file)
@@ -198,9 +198,10 @@ if ($PostScript ne '') {
     local($to_do);
     $PostScriptLines = `cat $PostScript`;
     $PostScriptLines =~ s/\r//g;
-    $* = 1;
-    $PostScriptLines =~ s#\$o1#$TmpPrefix/runtest$$.1#g;
-    $PostScriptLines =~ s#\$o2#$TmpPrefix/runtest$$.2#g;
+    $PostScriptLines =~ s#\$o1#$TmpPrefix/runtest$$.1#gm;
+    $PostScriptLines =~ s#\$o2#$TmpPrefix/runtest$$.2#gm;
+# The postfix 'm' deals with recent versions of 
+# Perl that removed the $* feature
 } else {
     $PostScriptLines = '';
 }
@@ -248,7 +249,7 @@ else
     $PostScriptLines
     hit='NO'
     for out_file in @PgmStdoutFile ; do
-       if sed "s/\\r\$//" $TmpPrefix/runtest$$.1 | cmp -s \$out_file - ; then
+       if sed "s/\r\$//" $TmpPrefix/runtest$$.1 | cmp -s \$out_file - ; then
            hit='YES'
        fi
     done
@@ -274,7 +275,7 @@ fi
 
 hit='NO'
 for out_file in @PgmStderrFile ; do
-    if sed "s/\\r\$//" $TmpPrefix/runtest$$.2 | cmp -s \$out_file - ; then
+    if sed "s/\r\$//" $TmpPrefix/runtest$$.2 | cmp -s \$out_file - ; then
        hit='YES'
     fi
 done
@@ -526,6 +527,10 @@ sub process_stats_file {
     $MaxResidency     = 0 unless defined($MaxResidency);
     $AvgResidency     = 0 unless defined($AvgResidency);
     $ResidencySamples = 0 unless defined($ResidencySamples);
+    $Gc0Time          = 0.0 unless defined($Gc0Time);
+    $Gc0Elapsed       = 0.0 unless defined($Gc0Elapsed);
+    $Gc1Time          = 0.0 unless defined($Gc1Time);
+    $Gc1Elapsed       = 0.0 unless defined($Gc1Elapsed);
 
     # a bit of tidying
     $BytesAlloc =~ s/,//g;