diff options
author | Christophe Lyon <christophe.lyon@linaro.org> | 2018-06-12 13:32:47 +0000 |
---|---|---|
committer | Christophe Lyon <christophe.lyon@linaro.org> | 2018-06-12 14:22:00 +0000 |
commit | 73ac1d89d01397d0a5bf208788c3c0abda0adf6d (patch) | |
tree | 9b2ead6f2a861f594e89fdb48c38eaecec88aca5 | |
parent | 71a76e74f4436bdb31f45a9c542a7daea50482b2 (diff) |
compare_dg_tests.pl: Add --hwdep-tests option
The new --hwdep-tests is similar to unstable-tests and provides a way
to specify a list of tests whose behaviour is considered as
hardware-dependent.
Such tests normally PASS is the hardware has the required feature,
they are skipped otherwise. This means that if such tests do not
always run the very same hardware, they appear/disappear from the
results.
To avoid noise in the results, this new flag allows to ignore such
cases.
It's OK for such tests to PASS, be UNSUPPORTED or absent from the
list. Other transitions are reported.
This patch implements TCWG-1421.
Change-Id: I25c125577ca795ea570342bcb95feef520096ff5
-rwxr-xr-x | compare_dg_tests.pl | 198 | ||||
-rwxr-xr-x | compare_tests | 5 | ||||
-rw-r--r-- | host-hw-dependent-tests.txt | 10 | ||||
-rw-r--r-- | testsuite/Makefile | 4 | ||||
-rw-r--r-- | testsuite/expected-1-2-long.txt | 50 | ||||
-rw-r--r-- | testsuite/expected-1-2.txt | 33 | ||||
-rw-r--r-- | testsuite/hw-dependent-tests.txt | 18 | ||||
-rw-r--r-- | testsuite/sum-1.txt | 10 | ||||
-rw-r--r-- | testsuite/sum-2.txt | 9 |
9 files changed, 225 insertions, 112 deletions
diff --git a/compare_dg_tests.pl b/compare_dg_tests.pl index 290c9a1..05acb44 100755 --- a/compare_dg_tests.pl +++ b/compare_dg_tests.pl @@ -94,80 +94,88 @@ my $ERROR_APPEARS = "ERROR appears [ =>ERROR]"; my $UNHANDLED_CASES = "Unhandled cases [ ..??.. ]"; my $UNSTABLE_CASES = "Unstable cases, ignored [~RANDOM ]"; - +my $HWDEP_CASES = "HW dependent cases [HW-DEPENDENT]"; + +# Handle status transitions: +# 'was' is the reference status +# 'is' is the current status +# 'cat' is the short name for the transition type +# 'handler' is a function handling the transition, if non-trivial +# report_hwdep is a boolean controlling whether to report the +# transition even if flagged as hardware-dependent my @handler_list = ( - {was=>"PASS", is=>"PASS", cat=>$PASS_PASS}, - {was=>"PASS", is=>"XPASS", cat=>$PASS_XPASS}, - {was=>"PASS", is=>"FAIL", handler=>\&handle_pass_fail}, - {was=>"PASS", is=>"XFAIL", cat=>$PASS_XFAIL}, - {was=>"PASS", is=>"UNSUPPORTED",cat=>$PASS_UNSUPPORTED}, - {was=>"PASS", is=>"UNTESTED", cat=>$PASS_UNTESTED}, - {was=>"PASS", is=>"UNRESOLVED",cat=>$PASS_UNRESOLVED}, - {was=>"PASS", is=>"NO_EXIST", cat=>$PASS_DISAPPEARS}, - {was=>"NO_EXIST", is=>"PASS", cat=>$PASS_APPEARS}, - - {was=>"XPASS", is=>"PASS", cat=>$XPASS_PASS}, - {was=>"XPASS", is=>"XPASS", cat=>$XPASS_XPASS}, - {was=>"XPASS", is=>"FAIL", cat=>$XPASS_FAIL}, - {was=>"XPASS", is=>"XFAIL", cat=>$XPASS_XFAIL}, - {was=>"XPASS", is=>"UNSUPPORTED",cat=>$XPASS_UNSUPPORTED}, - {was=>"XPASS", is=>"UNTESTED", cat=>$XPASS_UNTESTED}, - {was=>"XPASS", is=>"UNRESOLVED",cat=>$XPASS_UNRESOLVED}, - {was=>"XPASS", is=>"NO_EXIST", cat=>$XPASS_DISAPPEARS}, - {was=>"NO_EXIST", is=>"XPASS", cat=>$XPASS_APPEARS}, - - {was=>"FAIL", is=>"PASS", cat=>$FAIL_PASS}, - {was=>"FAIL", is=>"XPASS", cat=>$FAIL_XPASS}, - {was=>"FAIL", is=>"FAIL", cat=>$FAIL_FAIL}, - {was=>"FAIL", is=>"XFAIL", cat=>$FAIL_XFAIL}, - {was=>"FAIL", is=>"UNSUPPORTED",cat=>$FAIL_UNSUPPORTED}, - {was=>"FAIL", is=>"UNTESTED", cat=>$FAIL_UNTESTED}, - {was=>"FAIL", is=>"UNRESOLVED",cat=>$FAIL_UNRESOLVED}, - {was=>"FAIL", is=>"NO_EXIST", cat=>$FAIL_DISAPPEARS}, - {was=>"NO_EXIST", is=>"FAIL", cat=>$FAIL_APPEARS}, - - {was=>"XFAIL", is=>"PASS", cat=>$XFAIL_PASS}, - {was=>"XFAIL", is=>"XPASS", cat=>$XFAIL_XPASS}, - {was=>"XFAIL", is=>"FAIL", cat=>$XFAIL_FAIL}, - {was=>"XFAIL", is=>"XFAIL", cat=>$XFAIL_XFAIL}, - {was=>"XFAIL", is=>"UNSUPPORTED",cat=>$XFAIL_UNSUPPORTED}, - {was=>"XFAIL", is=>"UNTESTED", cat=>$XFAIL_UNTESTED}, - {was=>"XFAIL", is=>"UNRESOLVED",cat=>$XFAIL_UNRESOLVED}, - {was=>"XFAIL", is=>"NO_EXIST", cat=>$XFAIL_DISAPPEARS}, - {was=>"NO_EXIST", is=>"XFAIL", cat=>$XFAIL_APPEARS}, - - {was=>"UNSUPPORTED", is=>"PASS", cat=>$UNSUPPORTED_PASS}, - {was=>"UNSUPPORTED", is=>"XPASS", cat=>$UNSUPPORTED_XPASS}, - {was=>"UNSUPPORTED", is=>"FAIL", cat=>$UNSUPPORTED_FAIL}, - {was=>"UNSUPPORTED", is=>"XFAIL", cat=>$UNSUPPORTED_XFAIL}, - {was=>"UNSUPPORTED", is=>"UNSUPPORTED",cat=>$UNSUPPORTED_UNSUPPORTED}, - {was=>"UNSUPPORTED", is=>"UNTESTED", cat=>$UNSUPPORTED_UNTESTED}, - {was=>"UNSUPPORTED", is=>"UNRESOLVED",cat=>$UNSUPPORTED_UNRESOLVED}, - {was=>"UNSUPPORTED", is=>"NO_EXIST", cat=>$UNSUPPORTED_DISAPPEARS}, - {was=>"NO_EXIST", is=>"UNSUPPORTED", cat=>$UNSUPPORTED_APPEARS}, - - {was=>"UNTESTED", is=>"PASS", cat=>$UNTESTED_PASS}, - {was=>"UNTESTED", is=>"XPASS", cat=>$UNTESTED_XPASS}, - {was=>"UNTESTED", is=>"FAIL", cat=>$UNTESTED_FAIL}, - {was=>"UNTESTED", is=>"XFAIL", cat=>$UNTESTED_XFAIL}, - {was=>"UNTESTED", is=>"UNSUPPORTED",cat=>$UNTESTED_UNSUPPORTED}, - {was=>"UNTESTED", is=>"UNTESTED", cat=>$UNTESTED_UNTESTED}, - {was=>"UNTESTED", is=>"UNRESOLVED",cat=>$UNTESTED_UNRESOLVED}, - {was=>"UNTESTED", is=>"NO_EXIST", cat=>$UNTESTED_DISAPPEARS}, - {was=>"NO_EXIST", is=>"UNTESTED", cat=>$UNTESTED_APPEARS}, - - {was=>"UNRESOLVED", is=>"PASS", cat=>$UNRESOLVED_PASS}, - {was=>"UNRESOLVED", is=>"XPASS", cat=>$UNRESOLVED_XPASS}, - {was=>"UNRESOLVED", is=>"FAIL", cat=>$UNRESOLVED_FAIL}, - {was=>"UNRESOLVED", is=>"XFAIL", cat=>$UNRESOLVED_XFAIL}, - {was=>"UNRESOLVED", is=>"UNSUPPORTED",cat=>$UNRESOLVED_UNSUPPORTED}, - {was=>"UNRESOLVED", is=>"UNTESTED", cat=>$UNRESOLVED_UNTESTED}, - {was=>"UNRESOLVED", is=>"UNRESOLVED",cat=>$UNRESOLVED_UNRESOLVED}, - {was=>"UNRESOLVED", is=>"NO_EXIST", cat=>$UNRESOLVED_DISAPPEARS}, - {was=>"NO_EXIST", is=>"UNRESOLVED", cat=>$UNRESOLVED_APPEARS}, - - {was=>"ERROR", is=>"NO_EXIST", cat=>$ERROR_DISAPPEARS}, - {was=>"NO_EXIST", is=>"ERROR", cat=>$ERROR_APPEARS}, + {was=>"PASS", is=>"PASS", cat=>$PASS_PASS, report_hwdep=>"false"}, + {was=>"PASS", is=>"XPASS", cat=>$PASS_XPASS, report_hwdep=>"true"}, + {was=>"PASS", is=>"FAIL", handler=>\&handle_pass_fail, report_hwdep=>"true"}, + {was=>"PASS", is=>"XFAIL", cat=>$PASS_XFAIL, report_hwdep=>"true"}, + {was=>"PASS", is=>"UNSUPPORTED",cat=>$PASS_UNSUPPORTED, report_hwdep=>"false"}, + {was=>"PASS", is=>"UNTESTED", cat=>$PASS_UNTESTED, report_hwdep=>"true"}, + {was=>"PASS", is=>"UNRESOLVED",cat=>$PASS_UNRESOLVED, report_hwdep=>"true"}, + {was=>"PASS", is=>"NO_EXIST", cat=>$PASS_DISAPPEARS, report_hwdep=>"false"}, + {was=>"NO_EXIST", is=>"PASS", cat=>$PASS_APPEARS, report_hwdep=>"false"}, + + {was=>"XPASS", is=>"PASS", cat=>$XPASS_PASS, report_hwdep=>"true"}, + {was=>"XPASS", is=>"XPASS", cat=>$XPASS_XPASS, report_hwdep=>"true"}, + {was=>"XPASS", is=>"FAIL", cat=>$XPASS_FAIL, report_hwdep=>"true"}, + {was=>"XPASS", is=>"XFAIL", cat=>$XPASS_XFAIL, report_hwdep=>"true"}, + {was=>"XPASS", is=>"UNSUPPORTED",cat=>$XPASS_UNSUPPORTED, report_hwdep=>"true"}, + {was=>"XPASS", is=>"UNTESTED", cat=>$XPASS_UNTESTED, report_hwdep=>"true"}, + {was=>"XPASS", is=>"UNRESOLVED",cat=>$XPASS_UNRESOLVED, report_hwdep=>"true"}, + {was=>"XPASS", is=>"NO_EXIST", cat=>$XPASS_DISAPPEARS, report_hwdep=>"true"}, + {was=>"NO_EXIST", is=>"XPASS", cat=>$XPASS_APPEARS, report_hwdep=>"true"}, + + {was=>"FAIL", is=>"PASS", cat=>$FAIL_PASS, report_hwdep=>"true"}, + {was=>"FAIL", is=>"XPASS", cat=>$FAIL_XPASS, report_hwdep=>"true"}, + {was=>"FAIL", is=>"FAIL", cat=>$FAIL_FAIL, report_hwdep=>"true"}, + {was=>"FAIL", is=>"XFAIL", cat=>$FAIL_XFAIL, report_hwdep=>"true"}, + {was=>"FAIL", is=>"UNSUPPORTED",cat=>$FAIL_UNSUPPORTED, report_hwdep=>"true"}, + {was=>"FAIL", is=>"UNTESTED", cat=>$FAIL_UNTESTED, report_hwdep=>"true"}, + {was=>"FAIL", is=>"UNRESOLVED",cat=>$FAIL_UNRESOLVED, report_hwdep=>"true"}, + {was=>"FAIL", is=>"NO_EXIST", cat=>$FAIL_DISAPPEARS, report_hwdep=>"true"}, + {was=>"NO_EXIST", is=>"FAIL", cat=>$FAIL_APPEARS, report_hwdep=>"true"}, + + {was=>"XFAIL", is=>"PASS", cat=>$XFAIL_PASS, report_hwdep=>"true"}, + {was=>"XFAIL", is=>"XPASS", cat=>$XFAIL_XPASS, report_hwdep=>"true"}, + {was=>"XFAIL", is=>"FAIL", cat=>$XFAIL_FAIL, report_hwdep=>"true"}, + {was=>"XFAIL", is=>"XFAIL", cat=>$XFAIL_XFAIL, report_hwdep=>"true"}, + {was=>"XFAIL", is=>"UNSUPPORTED",cat=>$XFAIL_UNSUPPORTED, report_hwdep=>"true"}, + {was=>"XFAIL", is=>"UNTESTED", cat=>$XFAIL_UNTESTED, report_hwdep=>"true"}, + {was=>"XFAIL", is=>"UNRESOLVED",cat=>$XFAIL_UNRESOLVED, report_hwdep=>"true"}, + {was=>"XFAIL", is=>"NO_EXIST", cat=>$XFAIL_DISAPPEARS, report_hwdep=>"true"}, + {was=>"NO_EXIST", is=>"XFAIL", cat=>$XFAIL_APPEARS, report_hwdep=>"true"}, + + {was=>"UNSUPPORTED", is=>"PASS", cat=>$UNSUPPORTED_PASS, report_hwdep=>"true"}, + {was=>"UNSUPPORTED", is=>"XPASS", cat=>$UNSUPPORTED_XPASS, report_hwdep=>"true"}, + {was=>"UNSUPPORTED", is=>"FAIL", cat=>$UNSUPPORTED_FAIL, report_hwdep=>"true"}, + {was=>"UNSUPPORTED", is=>"XFAIL", cat=>$UNSUPPORTED_XFAIL, report_hwdep=>"true"}, + {was=>"UNSUPPORTED", is=>"UNSUPPORTED",cat=>$UNSUPPORTED_UNSUPPORTED, report_hwdep=>"true"}, + {was=>"UNSUPPORTED", is=>"UNTESTED", cat=>$UNSUPPORTED_UNTESTED, report_hwdep=>"true"}, + {was=>"UNSUPPORTED", is=>"UNRESOLVED",cat=>$UNSUPPORTED_UNRESOLVED, report_hwdep=>"true"}, + {was=>"UNSUPPORTED", is=>"NO_EXIST", cat=>$UNSUPPORTED_DISAPPEARS, report_hwdep=>"true"}, + {was=>"NO_EXIST", is=>"UNSUPPORTED", cat=>$UNSUPPORTED_APPEARS, report_hwdep=>"true"}, + + {was=>"UNTESTED", is=>"PASS", cat=>$UNTESTED_PASS, report_hwdep=>"true"}, + {was=>"UNTESTED", is=>"XPASS", cat=>$UNTESTED_XPASS, report_hwdep=>"true"}, + {was=>"UNTESTED", is=>"FAIL", cat=>$UNTESTED_FAIL, report_hwdep=>"true"}, + {was=>"UNTESTED", is=>"XFAIL", cat=>$UNTESTED_XFAIL, report_hwdep=>"true"}, + {was=>"UNTESTED", is=>"UNSUPPORTED",cat=>$UNTESTED_UNSUPPORTED,report_hwdep=>"true"}, + {was=>"UNTESTED", is=>"UNTESTED", cat=>$UNTESTED_UNTESTED, report_hwdep=>"true"}, + {was=>"UNTESTED", is=>"UNRESOLVED",cat=>$UNTESTED_UNRESOLVED, report_hwdep=>"true"}, + {was=>"UNTESTED", is=>"NO_EXIST", cat=>$UNTESTED_DISAPPEARS, report_hwdep=>"true"}, + {was=>"NO_EXIST", is=>"UNTESTED", cat=>$UNTESTED_APPEARS, report_hwdep=>"true"}, + + {was=>"UNRESOLVED", is=>"PASS", cat=>$UNRESOLVED_PASS, report_hwdep=>"true"}, + {was=>"UNRESOLVED", is=>"XPASS", cat=>$UNRESOLVED_XPASS, report_hwdep=>"true"}, + {was=>"UNRESOLVED", is=>"FAIL", cat=>$UNRESOLVED_FAIL, report_hwdep=>"true"}, + {was=>"UNRESOLVED", is=>"XFAIL", cat=>$UNRESOLVED_XFAIL, report_hwdep=>"true"}, + {was=>"UNRESOLVED", is=>"UNSUPPORTED",cat=>$UNRESOLVED_UNSUPPORTED, report_hwdep=>"true"}, + {was=>"UNRESOLVED", is=>"UNTESTED", cat=>$UNRESOLVED_UNTESTED, report_hwdep=>"true"}, + {was=>"UNRESOLVED", is=>"UNRESOLVED",cat=>$UNRESOLVED_UNRESOLVED, report_hwdep=>"true"}, + {was=>"UNRESOLVED", is=>"NO_EXIST", cat=>$UNRESOLVED_DISAPPEARS, report_hwdep=>"true"}, + {was=>"NO_EXIST", is=>"UNRESOLVED", cat=>$UNRESOLVED_APPEARS, report_hwdep=>"true"}, + + {was=>"ERROR", is=>"NO_EXIST", cat=>$ERROR_DISAPPEARS, report_hwdep=>"true"}, + {was=>"NO_EXIST", is=>"ERROR", cat=>$ERROR_APPEARS, report_hwdep=>"true"}, # {was=>"NO_EXIST", is=>"NO_EXIST", handler=>\&handle_not_yet_supported} ); @@ -185,6 +193,11 @@ my ($ref_file_name, $res_file_name); my $nounstable=0; my $unstablefile=0; my @unstable_markers=(); + +my $no_hwdep=0; # Ignore hw-dependent flag (ie. consider all tests as *not* hw-dependent +my $hwdep_file=0; # File containing the list of hw-dependent tests +my @hwdep_markers=(); # Optional markers when parsing hwdep_file + my $ratio_thresh = 0.95; # Warn if pass ratio is below this threshold GetOptions ("l" => \$long, @@ -197,7 +210,10 @@ GetOptions ("l" => \$long, "pass-thresh=f" => \$ratio_thresh, "no-unstable" => \$nounstable, "unstable-tests=s" => \$unstablefile, - "unstable-marker=s" => \@unstable_markers); + "unstable-marker=s" => \@unstable_markers, + "no-hwdep" => \$no_hwdep, + "hwdep-tests=s" => \$hwdep_file, + "hwdep-marker=s" => \@hwdep_markers); $ref_file_name = $ARGV[0] if ($#ARGV == 1); $res_file_name = $ARGV[1] if ($#ARGV == 1); @@ -224,6 +240,11 @@ my @unstablelist = (); @unstablelist = read_unstable($unstablefile) if ($unstablefile ne 0); +# Import list of hw-dependent files, if provided +my @hwdep_list = (); + +@hwdep_list = read_unstable($hwdep_file) if ($hwdep_file ne 0); + compare_results($ref, $res); my $final_result = print_compare_results_summary($ref, $res); @@ -312,7 +333,7 @@ sub read_sum($) return $res; } -# Parse list on unstable tests +# Parse list of unstable/hw-dependent tests sub read_unstable($) { my ($unstable_file) = @_; @@ -363,7 +384,17 @@ sub handle_pass_fail($$$$) } else { - push @{$res->{$PASS_FAIL}}, $tc; + # This transition is flagged as hw-dependent if: + # - the name is in the list + # - the transition should not be reported (but be flagged as hw-dependent instead) + # - --no-hwdep was not provided + if ((grep { (index $tc,$_)!=-1} @hwdep_list) + && ($diag_diag->{report_hwdep} eq "false") + && ($no_hwdep == 0)) { + push @{$res->{$HWDEP_CASES}}, $tc; + } else { + push @{$res->{$PASS_FAIL}}, $tc; + } } } @@ -447,6 +478,7 @@ sub compare_results($$) @{$res->{$UNHANDLED_CASES}} = (); @{$res->{$UNSTABLE_CASES}} = (); + @{$res->{$HWDEP_CASES}} = (); #### MERGE REF AND RES foreach my $key (sort (keys %{$res->{testcases}})) @@ -494,7 +526,17 @@ sub compare_results($$) } else { - push @{$res->{$diag_diag->{cat}}}, $key; + # This transition is flagged as hw-dependent if: + # - the name is in the list + # - the transition should not be reported (but be flagged as hw-dependent instead) + # - --no-hwdep was not provided + if ((grep { (index $key,$_)!=-1} @hwdep_list) + && ($diag_diag->{report_hwdep} eq "false") + && ($no_hwdep == 0)) { + push @{$res->{$HWDEP_CASES}}, $key; + } else { + push @{$res->{$diag_diag->{cat}}}, $key; + } } } } @@ -797,6 +839,7 @@ sub print_compare_results_summary($$) printf " | %-40s | %7d |\n", $ERROR_DISAPPEARS, scalar(@{$res->{$ERROR_DISAPPEARS}}) if (scalar(@{$res->{$ERROR_DISAPPEARS}})); printf " | %-40s | %7d |\n", $UNHANDLED_CASES, scalar(@{$res->{$UNHANDLED_CASES}}) if (scalar(@{$res->{$UNHANDLED_CASES}})); printf " | %-40s | %7d |\n", $UNSTABLE_CASES, scalar(@{$res->{$UNSTABLE_CASES}}) if (scalar(@{$res->{$UNSTABLE_CASES}})); + printf " | %-40s | %7d |\n", $HWDEP_CASES, scalar(@{$res->{$HWDEP_CASES}}) if (scalar(@{$res->{$HWDEP_CASES}})); printf " +------------------------------------------+---------+\n"; printf " | %-40s | %7d |\n", "TOTAL_MINOR_TO_BE_CHECKED", $total_better + scalar(@{$res->{$UNSTABLE_CASES}});; printf " +------------------------------------------+---------+\n"; @@ -845,6 +888,7 @@ sub print_compare_results_summary($$) print_tclist($res, $ERROR_DISAPPEARS, @{$res->{$ERROR_DISAPPEARS}}); print_tclist($res, $UNHANDLED_CASES, @{$res->{$UNHANDLED_CASES}}); print_tclist($res, $UNSTABLE_CASES, @{$res->{$UNSTABLE_CASES}}); + print_tclist($res, $HWDEP_CASES, @{$res->{$HWDEP_CASES}}); } printf "$col_reset\n"; } diff --git a/compare_tests b/compare_tests index 39f74a3..97b44bd 100755 --- a/compare_tests +++ b/compare_tests @@ -137,7 +137,10 @@ if [ -d "$1" -a -d "$2" ] ; then unstable_target="$unstable_target --unstable-marker $board" fi done - ${CONFIG_SHELL-/usr/bin/perl} ${my_path}/compare_dg_tests.pl ${pass_thresh:+-pass-thresh=${pass_thresh}} -l --unstable-test=${my_path}/unstable-tests.txt ${unstable_target} $sum1 $sum2 + ${CONFIG_SHELL-/usr/bin/perl} ${my_path}/compare_dg_tests.pl \ + ${pass_thresh:+-pass-thresh=${pass_thresh}} -l \ + --unstable-test=${my_path}/unstable-tests.txt ${unstable_target} \ + --hwdep-tests=${my_path}/host-hw-dependent-tests.txt $sum1 $sum2 ret=$? case $ret in 2) diff --git a/host-hw-dependent-tests.txt b/host-hw-dependent-tests.txt new file mode 100644 index 0000000..afddab4 --- /dev/null +++ b/host-hw-dependent-tests.txt @@ -0,0 +1,10 @@ +# List of tests which depend on the host HW +# Such tests PASS if the HW supports the feature, or are either absent +# or UNSUPPORTED otherwise. +# A FAIL should be reported as an error +# +# Syntax: +# target:test name +# +# gcc +gcc.dg/vect/vect-tail-nomask-1.c diff --git a/testsuite/Makefile b/testsuite/Makefile index 8925ba8..f1216c9 100644 --- a/testsuite/Makefile +++ b/testsuite/Makefile @@ -1,6 +1,6 @@ check: - LC_ALL=C ../compare_dg_tests.pl sum-1.txt sum-2.txt > cmp-1-2.txt ; diff cmp-1-2.txt expected-1-2.txt - LC_ALL=C ../compare_dg_tests.pl -l sum-1.txt sum-2.txt > cmp-1-2-long.txt ; diff cmp-1-2-long.txt expected-1-2-long.txt + LC_ALL=C ../compare_dg_tests.pl --hwdep-tests=hw-dependent-tests.txt sum-1.txt sum-2.txt > cmp-1-2.txt ; diff cmp-1-2.txt expected-1-2.txt + LC_ALL=C ../compare_dg_tests.pl --hwdep-tests=hw-dependent-tests.txt -l sum-1.txt sum-2.txt > cmp-1-2-long.txt ; diff cmp-1-2-long.txt expected-1-2-long.txt clean: rm -f cmp-1-2.txt diff --git a/testsuite/expected-1-2-long.txt b/testsuite/expected-1-2-long.txt index 11d79d0..60cf911 100644 --- a/testsuite/expected-1-2-long.txt +++ b/testsuite/expected-1-2-long.txt @@ -5,18 +5,18 @@ CURRENT: sum-2.txt ` +---------+---------+ o RUN STATUS: | REF | RES | +------------------------------------------+---------+---------+ - | Passes [PASS] | 9 | 11 | - | Unexpected fails [FAIL] | 10 | 10 | + | Passes [PASS] | 17 | 12 | + | Unexpected fails [FAIL] | 10 | 11 | | Errors [ERROR] | 1 | 1 | - | Unexpected passes [XPASS] | 8 | 9 | - | Expected fails [XFAIL] | 8 | 9 | - | Unresolved [UNRESOLVED] | 7 | 7 | - | Unsupported [UNSUPPORTED] | 7 | 7 | - | Untested [UNTESTED] | 7 | 7 | + | Unexpected passes [XPASS] | 8 | 10 | + | Expected fails [XFAIL] | 8 | 10 | + | Unresolved [UNRESOLVED] | 7 | 8 | + | Unsupported [UNSUPPORTED] | 7 | 8 | + | Untested [UNTESTED] | 7 | 8 | +------------------------------------------+---------+---------+ - REF PASS ratio: 0.303571 - RES PASS ratio: 0.333333 + REF PASS ratio: 0.390625 + RES PASS ratio: 0.328358 ***** ERROR: REF PASS ratio is abnormally low ***** ***** ERROR: RES PASS ratio is abnormally low ***** ***** ERROR: No REF execution test PASSed. Check execution engine configuration. ***** @@ -24,9 +24,9 @@ o RUN STATUS: | REF | RES | o REGRESSIONS: +------------------------------------------+---------+ - | PASS now XPASS [PASS =>XPASS] | 1 | - | PASS now FAIL [PASS => FAIL] | 1 | - | PASS now UNRESOLVED [PASS =>UNRES] | 1 | + | PASS now XPASS [PASS =>XPASS] | 2 | + | PASS now FAIL [PASS => FAIL] | 2 | + | PASS now UNRESOLVED [PASS =>UNRES] | 2 | | ERROR appears [ =>ERROR] | 1 | | XPASS now FAIL [XPASS=> FAIL] | 1 | | XPASS appears [ =>XPASS] | 1 | @@ -46,23 +46,29 @@ o REGRESSIONS: | UNRESOLVED now XPASS [UNRES=>XPASS] | 1 | | UNRESOLVED appears [ =>UNRES] | 1 | +------------------------------------------+---------+ - | TOTAL_REGRESSIONS | 21 | + | TOTAL_REGRESSIONS | 24 | +------------------------------------------+---------+ - PASS now XPASS [PASS =>XPASS]: + Executed from: hw-dep.exp + test2-hwdep-pass-xpass Executed from: tests-1.exp test2-pass-xpass - PASS now FAIL [PASS => FAIL]: + Executed from: hw-dep.exp + test3-hwdep-pass-fail Executed from: tests-1.exp test3-pass-fail - PASS now UNRESOLVED [PASS =>UNRES]: + Executed from: hw-dep.exp + test8-hwdep-pass-unresolved Executed from: tests-1.exp test8-pass-unresolved @@ -179,10 +185,10 @@ o REGRESSIONS: o MINOR TO BE CHECKED: +------------------------------------------+---------+ | PASS disappears [PASS => ] | 1 | - | PASS now XFAIL [PASS =>XFAIL] | 1 | + | PASS now XFAIL [PASS =>XFAIL] | 2 | | New PASS [ => PASS] | 1 | | PASS now UNSUPPORTED [PASS =>UNSUP] | 1 | - | PASS now UNTESTED [PASS =>UNTES] | 1 | + | PASS now UNTESTED [PASS =>UNTES] | 2 | | XPASS now PASS [XPASS=> PASS] | 1 | | XPASS now XFAIL [XPASS=>XFAIL] | 1 | | XPASS now UNSUPPORTED [XPASS=>UNSUP] | 1 | @@ -215,8 +221,9 @@ o MINOR TO BE CHECKED: | UNRESOLVED now UNTESTED [UNRES=>UNTES] | 1 | | UNRESOLVED disappears [UNRES=> ] | 1 | | ERROR disappears [ERROR=> ] | 1 | + | HW dependent cases [HW-DEPENDENT] | 2 | +------------------------------------------+---------+ - | TOTAL_MINOR_TO_BE_CHECKED | 38 | + | TOTAL_MINOR_TO_BE_CHECKED | 40 | +------------------------------------------+---------+ - PASS disappears [PASS => ]: @@ -227,6 +234,8 @@ o MINOR TO BE CHECKED: - PASS now XFAIL [PASS =>XFAIL]: + Executed from: hw-dep.exp + test4-hwdep-pass-xfail Executed from: tests-1.exp test4-pass-xfail @@ -245,6 +254,8 @@ o MINOR TO BE CHECKED: - PASS now UNTESTED [PASS =>UNTES]: + Executed from: hw-dep.exp + test7-hwdep-pass-untested Executed from: tests-1.exp test7-pass-untested @@ -455,4 +466,11 @@ o MINOR TO BE CHECKED: (DejaGnu) proc "scan-dump-tree-not fail_test optimized 1" does not exist. + - HW dependent cases [HW-DEPENDENT]: + + Executed from: hw-dep.exp + test5-hwdep-pass-disappears + test6-hwdep-pass-unsupported + + diff --git a/testsuite/expected-1-2.txt b/testsuite/expected-1-2.txt index 1d24ae9..858635c 100644 --- a/testsuite/expected-1-2.txt +++ b/testsuite/expected-1-2.txt @@ -5,18 +5,18 @@ CURRENT: sum-2.txt ` +---------+---------+ o RUN STATUS: | REF | RES | +------------------------------------------+---------+---------+ - | Passes [PASS] | 9 | 11 | - | Unexpected fails [FAIL] | 10 | 10 | + | Passes [PASS] | 17 | 12 | + | Unexpected fails [FAIL] | 10 | 11 | | Errors [ERROR] | 1 | 1 | - | Unexpected passes [XPASS] | 8 | 9 | - | Expected fails [XFAIL] | 8 | 9 | - | Unresolved [UNRESOLVED] | 7 | 7 | - | Unsupported [UNSUPPORTED] | 7 | 7 | - | Untested [UNTESTED] | 7 | 7 | + | Unexpected passes [XPASS] | 8 | 10 | + | Expected fails [XFAIL] | 8 | 10 | + | Unresolved [UNRESOLVED] | 7 | 8 | + | Unsupported [UNSUPPORTED] | 7 | 8 | + | Untested [UNTESTED] | 7 | 8 | +------------------------------------------+---------+---------+ - REF PASS ratio: 0.303571 - RES PASS ratio: 0.333333 + REF PASS ratio: 0.390625 + RES PASS ratio: 0.328358 ***** ERROR: REF PASS ratio is abnormally low ***** ***** ERROR: RES PASS ratio is abnormally low ***** ***** ERROR: No REF execution test PASSed. Check execution engine configuration. ***** @@ -24,9 +24,9 @@ o RUN STATUS: | REF | RES | o REGRESSIONS: +------------------------------------------+---------+ - | PASS now XPASS [PASS =>XPASS] | 1 | - | PASS now FAIL [PASS => FAIL] | 1 | - | PASS now UNRESOLVED [PASS =>UNRES] | 1 | + | PASS now XPASS [PASS =>XPASS] | 2 | + | PASS now FAIL [PASS => FAIL] | 2 | + | PASS now UNRESOLVED [PASS =>UNRES] | 2 | | ERROR appears [ =>ERROR] | 1 | | XPASS now FAIL [XPASS=> FAIL] | 1 | | XPASS appears [ =>XPASS] | 1 | @@ -46,17 +46,17 @@ o REGRESSIONS: | UNRESOLVED now XPASS [UNRES=>XPASS] | 1 | | UNRESOLVED appears [ =>UNRES] | 1 | +------------------------------------------+---------+ - | TOTAL_REGRESSIONS | 21 | + | TOTAL_REGRESSIONS | 24 | +------------------------------------------+---------+ o MINOR TO BE CHECKED: +------------------------------------------+---------+ | PASS disappears [PASS => ] | 1 | - | PASS now XFAIL [PASS =>XFAIL] | 1 | + | PASS now XFAIL [PASS =>XFAIL] | 2 | | New PASS [ => PASS] | 1 | | PASS now UNSUPPORTED [PASS =>UNSUP] | 1 | - | PASS now UNTESTED [PASS =>UNTES] | 1 | + | PASS now UNTESTED [PASS =>UNTES] | 2 | | XPASS now PASS [XPASS=> PASS] | 1 | | XPASS now XFAIL [XPASS=>XFAIL] | 1 | | XPASS now UNSUPPORTED [XPASS=>UNSUP] | 1 | @@ -89,8 +89,9 @@ o MINOR TO BE CHECKED: | UNRESOLVED now UNTESTED [UNRES=>UNTES] | 1 | | UNRESOLVED disappears [UNRES=> ] | 1 | | ERROR disappears [ERROR=> ] | 1 | + | HW dependent cases [HW-DEPENDENT] | 2 | +------------------------------------------+---------+ - | TOTAL_MINOR_TO_BE_CHECKED | 38 | + | TOTAL_MINOR_TO_BE_CHECKED | 40 | +------------------------------------------+---------+ diff --git a/testsuite/hw-dependent-tests.txt b/testsuite/hw-dependent-tests.txt new file mode 100644 index 0000000..4116de8 --- /dev/null +++ b/testsuite/hw-dependent-tests.txt @@ -0,0 +1,18 @@ +# List of tests which depend on the host HW +# Such tests PASS if the HW supports the feature, or are either absent +# or UNSUPPORTED otherwise. +# A FAIL should be reported as an error +# +# Syntax: +# target:test name +# +# gcc +test1-hwdep-pass-pass +test2-hwdep-pass-xpass +test3-hwdep-pass-fail +test4-hwdep-pass-xfail +test5-hwdep-pass-disappears +test6-hwdep-pass-unsupported +test7-hwdep-pass-untested +test8-hwdep-pass-unresolved + diff --git a/testsuite/sum-1.txt b/testsuite/sum-1.txt index 43fdb62..6947bbb 100644 --- a/testsuite/sum-1.txt +++ b/testsuite/sum-1.txt @@ -74,3 +74,13 @@ Running tests-9.exp ... FAIL: test1-fail-pass execution ERROR: (DejaGnu) proc "scan-dump-tree-not fail_test optimized 1" does not exist. + +Running hw-dep.exp ... +PASS: test1-hwdep-pass-pass +PASS: test2-hwdep-pass-xpass +PASS: test3-hwdep-pass-fail +PASS: test4-hwdep-pass-xfail +PASS: test5-hwdep-pass-disappears +PASS: test6-hwdep-pass-unsupported +PASS: test7-hwdep-pass-untested +PASS: test8-hwdep-pass-unresolved diff --git a/testsuite/sum-2.txt b/testsuite/sum-2.txt index caacdeb..4988088 100644 --- a/testsuite/sum-2.txt +++ b/testsuite/sum-2.txt @@ -82,3 +82,12 @@ Running tests-9.exp ... PASS: test1-fail-pass execution ERROR: (DejaGnu) proc "scan-dump-tree-not fail_test optimized 3" does not exist. + +Running hw-dep.exp ... +PASS: test1-hwdep-pass-pass +XPASS: test2-hwdep-pass-xpass +FAIL: test3-hwdep-pass-fail +XFAIL: test4-hwdep-pass-xfail +UNSUPPORTED: test6-hwdep-pass-unsupported +UNTESTED: test7-hwdep-pass-untested +UNRESOLVED: test8-hwdep-pass-unresolved |