public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* Fix testsuite profiling support checks
@ 2011-09-01 13:22 Bernd Schmidt
  2011-09-22 19:42 ` Bernd Schmidt
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Bernd Schmidt @ 2011-09-01 13:22 UTC (permalink / raw)
  To: GCC Patches, ro

[-- Attachment #1: Type: text/plain, Size: 835 bytes --]

The following change

	2011-05-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
	PR gcov-profile/48845

causes testsuite failures on C6X. Specifically,

@@ -495,11 +495,16 @@ proc check_profiling_available { test_wh
     # These conditions depend on the argument so examine them before
     # looking at the cache variable.

+    # Tree profiling requires TLS runtime support.
+    if { $test_what == "-fprofile-generate" } {
+       return [check_effective_target_tls_runtime]
+    }
+

skips all the further tests in that function if
check_effective_target_tls_runtime returns true. (I'm not sure why it
does that on C6X - it seems to link in emutls stuff?) We then fail with
unresolved __gcov symbols.

Fixed with the following patch. I've removed the new avr special case,
assuming it was intended to fix the same issue. Ok?


Bernd

[-- Attachment #2: supprof.diff --]
[-- Type: text/plain, Size: 881 bytes --]

	* testsuite/lib/target-supports.exp (check_profiling_available):
	Don't rely solely on TLS tests for -fprofile-generate, fall
	through to the other code.

Index: gcc/testsuite/lib/target-supports.exp
===================================================================
--- gcc/testsuite/lib/target-supports.exp	(revision 178293)
+++ gcc/testsuite/lib/target-supports.exp	(working copy)
@@ -459,12 +459,9 @@ proc check_profiling_available { test_wh
 
     # Tree profiling requires TLS runtime support.
     if { $test_what == "-fprofile-generate" } {
-	# AVR does not support profile generation because
-	# it does not implement needed support functions.
-	if { [istarget avr-*-*] } {
+	if { ![check_effective_target_tls_runtime] } {
 	    return 0
 	}
-	return [check_effective_target_tls_runtime]
     }
 
     # Support for -p on solaris2 relies on mcrt1.o which comes with the

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Fix testsuite profiling support checks
  2011-09-01 13:22 Fix testsuite profiling support checks Bernd Schmidt
@ 2011-09-22 19:42 ` Bernd Schmidt
  2011-09-23  2:32 ` Mike Stump
  2011-09-23 14:01 ` Rainer Orth
  2 siblings, 0 replies; 5+ messages in thread
From: Bernd Schmidt @ 2011-09-22 19:42 UTC (permalink / raw)
  To: GCC Patches, ro

On 09/01/11 15:20, Bernd Schmidt wrote:
> The following change
> 
> 	2011-05-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
> 	PR gcov-profile/48845
> 
> causes testsuite failures on C6X. Specifically,
> 
> @@ -495,11 +495,16 @@ proc check_profiling_available { test_wh
>      # These conditions depend on the argument so examine them before
>      # looking at the cache variable.
> 
> +    # Tree profiling requires TLS runtime support.
> +    if { $test_what == "-fprofile-generate" } {
> +       return [check_effective_target_tls_runtime]
> +    }
> +
> 
> skips all the further tests in that function if
> check_effective_target_tls_runtime returns true. (I'm not sure why it
> does that on C6X - it seems to link in emutls stuff?) We then fail with
> unresolved __gcov symbols.
> 
> Fixed with the following patch. I've removed the new avr special case,
> assuming it was intended to fix the same issue. Ok?

Ping?


Bernd

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Fix testsuite profiling support checks
  2011-09-01 13:22 Fix testsuite profiling support checks Bernd Schmidt
  2011-09-22 19:42 ` Bernd Schmidt
@ 2011-09-23  2:32 ` Mike Stump
  2011-09-23 14:16   ` Rainer Orth
  2011-09-23 14:01 ` Rainer Orth
  2 siblings, 1 reply; 5+ messages in thread
From: Mike Stump @ 2011-09-23  2:32 UTC (permalink / raw)
  To: Bernd Schmidt; +Cc: GCC Patches, ro

On Sep 1, 2011, at 6:20 AM, Bernd Schmidt wrote:
> The following change
> 
> 	2011-05-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
> 	PR gcov-profile/48845
> 
> causes testsuite failures on C6X.

I was hoping that Rainer would comment...  or a profiling person, or an avr person....

> Ok?

Ok.  Watch for any hate mail from the avr folks.  :-)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Fix testsuite profiling support checks
  2011-09-01 13:22 Fix testsuite profiling support checks Bernd Schmidt
  2011-09-22 19:42 ` Bernd Schmidt
  2011-09-23  2:32 ` Mike Stump
@ 2011-09-23 14:01 ` Rainer Orth
  2 siblings, 0 replies; 5+ messages in thread
From: Rainer Orth @ 2011-09-23 14:01 UTC (permalink / raw)
  To: Bernd Schmidt; +Cc: GCC Patches

Bernd Schmidt <bernds@codesourcery.com> writes:

> The following change
>
> 	2011-05-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
> 	PR gcov-profile/48845
>
> causes testsuite failures on C6X. Specifically,
>
> @@ -495,11 +495,16 @@ proc check_profiling_available { test_wh
>      # These conditions depend on the argument so examine them before
>      # looking at the cache variable.
>
> +    # Tree profiling requires TLS runtime support.
> +    if { $test_what == "-fprofile-generate" } {
> +       return [check_effective_target_tls_runtime]
> +    }
> +
>
> skips all the further tests in that function if
> check_effective_target_tls_runtime returns true. (I'm not sure why it
> does that on C6X - it seems to link in emutls stuff?) We then fail with

Right, this is always present and satisfies the tls_runtime test.  The
check was primarily meant for targets that have native TLS, but need
special switches to enable it.

	Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Fix testsuite profiling support checks
  2011-09-23  2:32 ` Mike Stump
@ 2011-09-23 14:16   ` Rainer Orth
  0 siblings, 0 replies; 5+ messages in thread
From: Rainer Orth @ 2011-09-23 14:16 UTC (permalink / raw)
  To: Mike Stump; +Cc: Bernd Schmidt, GCC Patches

Mike Stump <mikestump@comcast.net> writes:

> On Sep 1, 2011, at 6:20 AM, Bernd Schmidt wrote:
>> The following change
>> 
>> 	2011-05-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
>> 	PR gcov-profile/48845
>> 
>> causes testsuite failures on C6X.
>
> I was hoping that Rainer would comment...  or a profiling person, or an avr person....

I've just returned from a 3-week vacation and am slowly working through
my mail.

>> Ok?
>
> Ok.  Watch for any hate mail from the avr folks.  :-)

Looks good.  I'm just running a Solaris 8/x86 bootstrap, which will
notice if something's amiss for that target.

Thanks.
	Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-09-23 12:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-01 13:22 Fix testsuite profiling support checks Bernd Schmidt
2011-09-22 19:42 ` Bernd Schmidt
2011-09-23  2:32 ` Mike Stump
2011-09-23 14:16   ` Rainer Orth
2011-09-23 14:01 ` Rainer Orth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).