1 # This harness is
for tests that should be run at all optimisation levels.
4 load_lib gcc
-gdb
-test.exp
6 # Disable
on darwin until radr
://7264615 is resolved.
7 if { [istarget
*-*-darwin
*] } {
11 if { [istarget
"powerpc-ibm-aix*"] } {
12 set torture_execute_xfail
"powerpc-ibm-aix*"
16 proc check_guality
{args} {
17 # Don
't count check_guality as PASS, or FAIL etc., that would make
18 # the total PASS count dependent on how many parallel runtest invocations
19 # ran guality.exp. So save the counts first and restore them afterwards.
21 array set saved_test_counts [array get test_counts]
22 set result [eval check_compile guality_check executable $args "-g -O0"]
23 set lines [lindex $result 0]
24 set output [lindex $result 1]
26 if {[string match "" $lines]} {
27 set execout [g++_load "./$output"]
28 set ret [string match "*1 PASS, 0 FAIL, 0 UNRESOLVED*" $execout]
30 remote_file build delete $output
31 array get test_counts [array get saved_test_counts]
38 if ![info exists ::env(GUALITY_GDB_NAME)] {
39 if [info exists GDB] {
40 set guality_gdb_name "$GDB"
42 set guality_gdb_name "[transform gdb]"
44 setenv GUALITY_GDB_NAME "$guality_gdb_name"
48 #include \"$srcdir/$subdir/guality.h\"
49 volatile long int varl = 6;
50 int main (int argc, char *argv\[\])
56 gcc-dg-runtest [lsort [glob $srcdir/$subdir/*.C]] "" ""
57 gcc-dg-runtest [lsort [glob $srcdir/c-c++-common/guality/*.c]] "" ""
60 if [info exists guality_gdb_name] {
61 unsetenv GUALITY_GDB_NAME