public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* RFA: Skip SH interrupt tests for PIC flags
@ 2007-08-12 10:02 Richard Sandiford
  2007-08-12 13:11 ` Kaz Kojima
  2007-08-13 23:23 ` Janis Johnson
  0 siblings, 2 replies; 3+ messages in thread
From: Richard Sandiford @ 2007-08-12 10:02 UTC (permalink / raw)
  To: gcc-patches

gcc.dg has several SH interrupt tests that fail on VxWorks for -mrtp -fPIC.
Of course, interrupt functions are not something you'd normally use SVR4-
or RTP-style PIC for, but for completeness:

   attr-isr-nosave_low_regs.c
   pragma-isr-nosave_low_regs.c
      - Checks that we don't save and restore r8-r13, but we need to
        save and restore r12 (the global pointer).
      - Checks that a low register doesn't appear before a comma,
        but r0 appears in "(r0,r12)" GOT accesses.

   attr-isr-trapa.c
   pragma-isr-trapa.c
      - Checks that there are no occurences of r8-r13, but we again
        need r12.

   attr-isr.c
   pragma-isr-trapa2.c
      - As for attr-isr-trapa.c.
      - Checks for a certain number of low-register references, but GOT
        loads mean that there are more "r0,"s than expected.

Is the patch below OK?  Tested on sh-wrs-vxworks.

Richard


gcc/testsuite/
	* gcc.dg/attr-isr.c: Skip for PIC.
	* gcc.dg/attr-isr-nosave_low_regs.c: Likewise.
	* gcc.dg/attr-isr-trapa.c: Likewise.
	* gcc.dg/pragma-isr-nosave_low_regs.c: Likewise.
	* gcc.dg/pragma-isr-trapa.c: Likewise.
	* gcc.dg/pragma-isr-trapa2.c: Likewise.

Index: gcc/testsuite/gcc.dg/attr-isr.c
===================================================================
--- gcc/testsuite/gcc.dg/attr-isr.c	(revision 127359)
+++ gcc/testsuite/gcc.dg/attr-isr.c	(working copy)
@@ -1,4 +1,4 @@
-/* { dg-do compile { target sh-*-* sh[1234ble]*-*-*} } */
+/* { dg-do compile { target { { sh-*-* sh[1234ble]*-*-* } && nonpic } } } */
 /* { dg-options "-O" } */
 extern void foo ();
 
Index: gcc/testsuite/gcc.dg/attr-isr-nosave_low_regs.c
===================================================================
--- gcc/testsuite/gcc.dg/attr-isr-nosave_low_regs.c	(revision 127359)
+++ gcc/testsuite/gcc.dg/attr-isr-nosave_low_regs.c	(working copy)
@@ -1,4 +1,4 @@
-/* { dg-do compile { target sh-*-* sh[1234ble]*-*-*} } */
+/* { dg-do compile { target { { sh-*-* sh[1234ble]*-*-* } && nonpic } } } */
 /* { dg-options "-O" } */
 
 extern void bar ();
Index: gcc/testsuite/gcc.dg/attr-isr-trapa.c
===================================================================
--- gcc/testsuite/gcc.dg/attr-isr-trapa.c	(revision 127359)
+++ gcc/testsuite/gcc.dg/attr-isr-trapa.c	(working copy)
@@ -1,4 +1,4 @@
-/* { dg-do compile { target sh-*-* sh[1234ble]*-*-*} } */
+/* { dg-do compile { target { { sh-*-* sh[1234ble]*-*-* } && nonpic } } } */
 /* { dg-options "-O" } */
 extern void foo ();
 
Index: gcc/testsuite/gcc.dg/pragma-isr-nosave_low_regs.c
===================================================================
--- gcc/testsuite/gcc.dg/pragma-isr-nosave_low_regs.c	(revision 127359)
+++ gcc/testsuite/gcc.dg/pragma-isr-nosave_low_regs.c	(working copy)
@@ -1,4 +1,4 @@
-/* { dg-do compile { target sh-*-* sh[1234ble]*-*-*} } */
+/* { dg-do compile { target { { sh-*-* sh[1234ble]*-*-* } && nonpic } } } */
 /* { dg-options "-O" } */
 extern void foo ();
 #pragma interrupt
Index: gcc/testsuite/gcc.dg/pragma-isr-trapa.c
===================================================================
--- gcc/testsuite/gcc.dg/pragma-isr-trapa.c	(revision 127359)
+++ gcc/testsuite/gcc.dg/pragma-isr-trapa.c	(working copy)
@@ -1,4 +1,4 @@
-/* { dg-do compile { target sh-*-* sh[1234ble]*-*-*} } */
+/* { dg-do compile { target { { sh-*-* sh[1234ble]*-*-* } && nonpic } } } */
 /* { dg-options "-O" } */
 extern void foo ();
 #pragma trapa
Index: gcc/testsuite/gcc.dg/pragma-isr-trapa2.c
===================================================================
--- gcc/testsuite/gcc.dg/pragma-isr-trapa2.c	(revision 127359)
+++ gcc/testsuite/gcc.dg/pragma-isr-trapa2.c	(working copy)
@@ -1,4 +1,4 @@
-/* { dg-do compile { target sh-*-* sh4*-*-*} } */
+/* { dg-do compile { target { { sh-*-* sh4*-*-* } && nonpic } } } */
 /* { dg-options "-O -m4" } */
 
 extern void foo ();

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

* Re: RFA: Skip SH interrupt tests for PIC flags
  2007-08-12 10:02 RFA: Skip SH interrupt tests for PIC flags Richard Sandiford
@ 2007-08-12 13:11 ` Kaz Kojima
  2007-08-13 23:23 ` Janis Johnson
  1 sibling, 0 replies; 3+ messages in thread
From: Kaz Kojima @ 2007-08-12 13:11 UTC (permalink / raw)
  To: richard; +Cc: gcc-patches

Richard Sandiford <richard@codesourcery.com> wrote:
> gcc/testsuite/
> 	* gcc.dg/attr-isr.c: Skip for PIC.
> 	* gcc.dg/attr-isr-nosave_low_regs.c: Likewise.
> 	* gcc.dg/attr-isr-trapa.c: Likewise.
> 	* gcc.dg/pragma-isr-nosave_low_regs.c: Likewise.
> 	* gcc.dg/pragma-isr-trapa.c: Likewise.
> 	* gcc.dg/pragma-isr-trapa2.c: Likewise.

This patch is OK.  Thanks!

Regards,
	kaz

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

* Re: RFA: Skip SH interrupt tests for PIC flags
  2007-08-12 10:02 RFA: Skip SH interrupt tests for PIC flags Richard Sandiford
  2007-08-12 13:11 ` Kaz Kojima
@ 2007-08-13 23:23 ` Janis Johnson
  1 sibling, 0 replies; 3+ messages in thread
From: Janis Johnson @ 2007-08-13 23:23 UTC (permalink / raw)
  To: Richard Sandiford; +Cc: gcc-patches

On Sun, 2007-08-12 at 11:02 +0100, Richard Sandiford wrote:
> Is the patch below OK?  Tested on sh-wrs-vxworks.

> gcc/testsuite/
> 	* gcc.dg/attr-isr.c: Skip for PIC.
> 	* gcc.dg/attr-isr-nosave_low_regs.c: Likewise.
> 	* gcc.dg/attr-isr-trapa.c: Likewise.
> 	* gcc.dg/pragma-isr-nosave_low_regs.c: Likewise.
> 	* gcc.dg/pragma-isr-trapa.c: Likewise.
> 	* gcc.dg/pragma-isr-trapa2.c: Likewise.

It looks fine from a test perspective, but you might want to
wait a couple of days to see if there are objections from sh
or vxworks people.

Janis

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

end of thread, other threads:[~2007-08-13 23:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-08-12 10:02 RFA: Skip SH interrupt tests for PIC flags Richard Sandiford
2007-08-12 13:11 ` Kaz Kojima
2007-08-13 23:23 ` 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).