]> gcc.gnu.org Git - gcc.git/blobdiff - gcc/testsuite/lib/target-supports.exp
target-supports.exp (check_profiling_available): Check argument to determine whether...
[gcc.git] / gcc / testsuite / lib / target-supports.exp
index 33d72fd9520703ad5b2632cf1d127c68a53205c8..173ce6128d38c428058df3a608ebfd573e538fca 100644 (file)
@@ -166,9 +166,32 @@ proc check_gc_sections_available { } {
 
 # Return true if profiling is supported on the target.
 
-proc check_profiling_available { } {
+proc check_profiling_available { test_what } {
     global profiling_available_saved
 
+    verbose "Profiling argument is <$test_what>" 1
+
+    # These conditions depend on the argument so examine them before
+    # looking at the cache variable.
+
+    # Support for -p on solaris2 relies on mcrt1.o which comes with the
+    # vendor compiler.  We cannot reliably predict the directory where the
+    # vendor compiler (and thus mcrt1.o) is installed so we can't
+    # necessarily find mcrt1.o even if we have it.
+    if { [istarget *-*-solaris2*] && [lindex $test_what 1] == "-p" } {
+       return 0
+    }
+
+    # Support for -p on irix relies on libprof1.a which doesn't appear to
+    # exist on any irix6 system currently posting testsuite results.
+    # Support for -pg on irix relies on gcrt1.o which doesn't exist yet.
+    # See: http://gcc.gnu.org/ml/gcc/2002-10/msg00169.html
+    if { [istarget mips*-*-irix*] 
+    && ([lindex $test_what 1] == "-p" || [lindex $test_what 1] == "-pg") } {
+       return 0
+    }
+
+    # Now examine the cache variable.
     if {![info exists profiling_available_saved]} {
        # Some targets don't have any implementation of __bb_init_func or are
        # missing other needed machinery.
This page took 1.002419 seconds and 5 git commands to generate.