From: Richard Sandiford <richard@codesourcery.com>
To: gcc-patches@gcc.gnu.org
Subject: RFA: Skip SH interrupt tests for PIC flags
Date: Sun, 12 Aug 2007 10:02:00 -0000 [thread overview]
Message-ID: <877io1m5pc.fsf@firetop.home> (raw)
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 ();
next reply other threads:[~2007-08-12 10:02 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-12 10:02 Richard Sandiford [this message]
2007-08-12 13:11 ` Kaz Kojima
2007-08-13 23:23 ` Janis Johnson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=877io1m5pc.fsf@firetop.home \
--to=richard@codesourcery.com \
--cc=gcc-patches@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).