public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [testsuite patch] check before using -mthumb in 5 arm tests
@ 2014-08-08  0:31 Janis Johnson
  2014-08-08 10:41 ` Richard Earnshaw
  0 siblings, 1 reply; 2+ messages in thread
From: Janis Johnson @ 2014-08-08  0:31 UTC (permalink / raw)
  To: gcc-patches

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

Five tests in gcc.target/arm add -mthumb without first checking that the
option is compatible with the current multilib flags.  This patch fixes
that by skipping each test if neither arm_thumb1_ok or arm_thumb2_ok is
true.  Tested by running gcc.target/arm tests with a variety of multilib
flags, some of which now skip these tests instead of failing to compile.
OK for mainline and the 4.9 branch?

Janis

[-- Attachment #2: gcc-20140807-2 --]
[-- Type: text/plain, Size: 3025 bytes --]

2013-08-07  Janis Johnson  <janisjo@codesourcery.com>

	* gcc.target/arm/frame-pointer-1.c: Skip if Thumb is not supported.
	* gcc.target/arm/pr56184.C: Likewise.
	* gcc.target/arm/pr59896.c: Likewise.
	* gcc.target/arm/stack-red-zone.c: Likewise.
	* gcc.target/arm/thumb-find-work-register.c: Likewise.

Index: gcc/testsuite/gcc.target/arm/frame-pointer-1.c
===================================================================
--- gcc/testsuite/gcc.target/arm/frame-pointer-1.c	(revision 213683)
+++ gcc/testsuite/gcc.target/arm/frame-pointer-1.c	(working copy)
@@ -1,6 +1,7 @@
 /* Check local register variables using a register conventionally 
    used as the frame pointer aren't clobbered under high register pressure.  */
 /* { dg-do run } */
+/* { dg-skip-if "incompatible options" { ! { arm_thumb1_ok || arm_thumb2_ok } } { "*" } { "" } } */
 /* { dg-options "-Os -mthumb -fomit-frame-pointer" } */
 
 #include <stdlib.h>
Index: gcc/testsuite/gcc.target/arm/pr56184.C
===================================================================
--- gcc/testsuite/gcc.target/arm/pr56184.C	(revision 213683)
+++ gcc/testsuite/gcc.target/arm/pr56184.C	(working copy)
@@ -1,4 +1,5 @@
 /* { dg-do compile } */
+/* { dg-skip-if "incompatible options" { ! { arm_thumb1_ok || arm_thumb2_ok } } { "*" } { "" } } */
 /* { dg-options "-fno-short-enums -O2 -mthumb -march=armv7-a -mfpu=neon -mfloat-abi=softfp -mtune=cortex-a9 -fno-section-anchors" } */
 
 typedef unsigned int size_t;
Index: gcc/testsuite/gcc.target/arm/pr59896.c
===================================================================
--- gcc/testsuite/gcc.target/arm/pr59896.c	(revision 213683)
+++ gcc/testsuite/gcc.target/arm/pr59896.c	(working copy)
@@ -1,4 +1,5 @@
 /* { dg-do compile } */
+/* { dg-skip-if "incompatible options" { ! { arm_thumb1_ok || arm_thumb2_ok } } { "*" } { "" } } */
 /* { dg-options "-mthumb -O2" } */
 
 typedef unsigned int size_t;
Index: gcc/testsuite/gcc.target/arm/stack-red-zone.c
===================================================================
--- gcc/testsuite/gcc.target/arm/stack-red-zone.c	(revision 213683)
+++ gcc/testsuite/gcc.target/arm/stack-red-zone.c	(working copy)
@@ -1,4 +1,5 @@
 /* No stack red zone.  PR38644.  */
+/* { dg-skip-if "incompatible options" { ! { arm_thumb1_ok || arm_thumb2_ok } } { "*" } { "" } } */
 /* { dg-options "-mthumb -O2" } */
 /* { dg-final { scan-assembler "ldrb\[^\n\]*\\n\[\t \]*add\[\t \]*sp" } } */
 
Index: gcc/testsuite/gcc.target/arm/thumb-find-work-register.c
===================================================================
--- gcc/testsuite/gcc.target/arm/thumb-find-work-register.c	(revision 213683)
+++ gcc/testsuite/gcc.target/arm/thumb-find-work-register.c	(working copy)
@@ -1,5 +1,6 @@
 /* Wrong method to get number of arg reg will cause argument corruption.  */
 /* { dg-do run } */
+/* { dg-skip-if "incompatible options" { ! { arm_thumb1_ok || arm_thumb2_ok } } { "*" } { "" } } */
 /* { dg-require-effective-target arm_eabi } */
 /* { dg-options "-mthumb -O1" } */
 

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

* Re: [testsuite patch] check before using -mthumb in 5 arm tests
  2014-08-08  0:31 [testsuite patch] check before using -mthumb in 5 arm tests Janis Johnson
@ 2014-08-08 10:41 ` Richard Earnshaw
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Earnshaw @ 2014-08-08 10:41 UTC (permalink / raw)
  To: janisjo; +Cc: Janis Johnson, gcc-patches

On 08/08/14 01:31, Janis Johnson wrote:
> Five tests in gcc.target/arm add -mthumb without first checking that the
> option is compatible with the current multilib flags.  This patch fixes
> that by skipping each test if neither arm_thumb1_ok or arm_thumb2_ok is
> true.  Tested by running gcc.target/arm tests with a variety of multilib
> flags, some of which now skip these tests instead of failing to compile.
> OK for mainline and the 4.9 branch?
> 
> Janis
> 
> 
> gcc-20140807-2
> 
> 
> 2013-08-07  Janis Johnson  <janisjo@codesourcery.com>
> 
> 	* gcc.target/arm/frame-pointer-1.c: Skip if Thumb is not supported.
> 	* gcc.target/arm/pr56184.C: Likewise.
> 	* gcc.target/arm/pr59896.c: Likewise.
> 	* gcc.target/arm/stack-red-zone.c: Likewise.
> 	* gcc.target/arm/thumb-find-work-register.c: Likewise.

OK.

R.


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

end of thread, other threads:[~2014-08-08 10:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-08  0:31 [testsuite patch] check before using -mthumb in 5 arm tests Janis Johnson
2014-08-08 10:41 ` Richard Earnshaw

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