public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH,testsuite] skip two tests with -mlongcall on powerpc targets
@ 2007-08-02 19:15 Nathan Froyd
  2007-08-03  3:27 ` Janis Johnson
  0 siblings, 1 reply; 2+ messages in thread
From: Nathan Froyd @ 2007-08-02 19:15 UTC (permalink / raw)
  To: gcc-patches

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

The attached patch skips two tests on powerpc targets if -mlongcall is
in effect.  Essentially, if -mlongcall is in effect, then we place
function addresses into the CTR register and bctrl instead of calling
the function directly, as the tests expect.

Tested on powerpc64-unknown-linux-gnu and powerpc-wrs-vxworks.  OK to
commit?

-Nathan

2007-08-02  Nathan Froyd  <froydnj@codesourcery.com>

	gcc/testsuite/
	* gcc.dg/tree-ssa/loop-1.c: Skip on powerpc targets if -mlongcall.
	* gcc.dg/weak/typeof-2.c: Likewise.


[-- Attachment #2: mlongcall.patch --]
[-- Type: text/plain, Size: 1359 bytes --]

Index: gcc/testsuite/gcc.dg/tree-ssa/loop-1.c
===================================================================
--- gcc/testsuite/gcc.dg/tree-ssa/loop-1.c	(revision 178052)
+++ gcc/testsuite/gcc.dg/tree-ssa/loop-1.c	(working copy)
@@ -1,4 +1,6 @@
 /* { dg-do compile } */
+/* -mlongcall will cause us to place &foo in the CTR register.  */
+/* { dg-skip-if "" { powerpc*-*-* } { "-mlongcall" } { "" } } */
 /* { dg-options "-O1 -ftree-loop-ivcanon -funroll-loops -fdump-tree-ivcanon-details -fdump-tree-cunroll-details -fdump-tree-vars" } */
 
 /* On 31-bit S/390 the function address will be stored (once) in the literal pool,
@@ -44,4 +46,3 @@ void xxx(void)
 /* { dg-final { scan-assembler-times "Jsr \\\$r" 5 { target cris-*-* } } } */
 /* { dg-final { scan-assembler-times "\[jb\]sr" 5 { target m68k-*-* } } } */
 
-
Index: gcc/testsuite/gcc.dg/weak/typeof-2.c
===================================================================
--- gcc/testsuite/gcc.dg/weak/typeof-2.c	(revision 178052)
+++ gcc/testsuite/gcc.dg/weak/typeof-2.c	(working copy)
@@ -1,5 +1,7 @@
 /* Test typeof with __asm redirection. */
 /* { dg-do compile } */
+/* -mlongcall will cause us to place &baz3 in the CTR register.  */
+/* { dg-skip-if "" { powerpc*-*-* } { "-mlongcall" } { "" } } */
 /* { dg-require-weak "" } */
 /* { dg-require-alias "" } */
 /* { dg-options "-O2" } */

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

* Re: [PATCH,testsuite] skip two tests with -mlongcall on powerpc  targets
  2007-08-02 19:15 [PATCH,testsuite] skip two tests with -mlongcall on powerpc targets Nathan Froyd
@ 2007-08-03  3:27 ` Janis Johnson
  0 siblings, 0 replies; 2+ messages in thread
From: Janis Johnson @ 2007-08-03  3:27 UTC (permalink / raw)
  To: Nathan Froyd; +Cc: gcc-patches

On Thu, 2007-08-02 at 12:15 -0700, Nathan Froyd wrote:
> The attached patch skips two tests on powerpc targets if -mlongcall is
> in effect.  Essentially, if -mlongcall is in effect, then we place
> function addresses into the CTR register and bctrl instead of calling
> the function directly, as the tests expect.
> 
> Tested on powerpc64-unknown-linux-gnu and powerpc-wrs-vxworks.  OK to
> commit?

OK.

Janis

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

end of thread, other threads:[~2007-08-03  3:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-08-02 19:15 [PATCH,testsuite] skip two tests with -mlongcall on powerpc targets Nathan Froyd
2007-08-03  3:27 ` Janis Johnson

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).