This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 2/2] Add some more test cases for fentry and pg
- From: Andi Kleen <andi at firstfloor dot org>
- To: Andi Kleen <andi at firstfloor dot org>
- Cc: Dominique Dhumieres <dominiq at lps dot ens dot fr>, gcc-patches at gcc dot gnu dot org, iain at codesourcery dot com
- Date: Wed, 17 Sep 2014 16:39:00 +0200
- Subject: Re: [PATCH 2/2] Add some more test cases for fentry and pg
- Authentication-results: sourceware.org; auth=none
- References: <20140917134237 dot D6D77100 at mailhost dot lps dot ens dot fr> <20140917143220 dot GX4120 at two dot firstfloor dot org>
On Wed, Sep 17, 2014 at 04:32:21PM +0200, Andi Kleen wrote:
> On Wed, Sep 17, 2014 at 03:42:37PM +0200, Dominique Dhumieres wrote:
> >
> > On darwin I get
> >
> > FAIL: gcc.target/i386/fentry-override.c (test for excess errors)
> > UNRESOLVED: gcc.target/i386/fentry-override.c scan-assembler-not __fentry__
> > FAIL: gcc.target/i386/fentry.c (test for excess errors)
> > UNRESOLVED: gcc.target/i386/fentry.c scan-assembler __fentry__
> >
> > with -m32. The error is
> >
> > sorry, unimplemented: -mfentry isn't supported for 32-bit in combination with -fpic
> >
> > With -m64 I get
> >
> > FAIL: gcc.target/i386/fentry.c scan-assembler __fentry__
> >
> > with no string 'entry' in the fentry.s file.
>
> __fentry__ doesn't exist on all x86 targets.
> I'm not sure how to mark a test to be Linux only. I'll just remove it.
Ok, this should fix it:
I'll commit it as obvious after testing unless there are objections.
diff --git a/gcc/testsuite/gcc.target/i386/fentry-override.c b/gcc/testsuite/gcc.target/i386/fentry-override.c
index 3771f19..1b158b3 100644
--- a/gcc/testsuite/gcc.target/i386/fentry-override.c
+++ b/gcc/testsuite/gcc.target/i386/fentry-override.c
@@ -1,5 +1,5 @@
/* Test -mfentry override */
-/* { dg-do compile } */
+/* { dg-do compile { target { *-*-linux* } } } */
/* { dg-options "-mfentry" } */
/* { dg-final { scan-assembler-not "__fentry__" } } */
/* Origin: Andi Kleen */
diff --git a/gcc/testsuite/gcc.target/i386/fentry.c b/gcc/testsuite/gcc.target/i386/fentry.c
index bd3db13..2222888 100644
--- a/gcc/testsuite/gcc.target/i386/fentry.c
+++ b/gcc/testsuite/gcc.target/i386/fentry.c
@@ -1,5 +1,5 @@
/* Test -mfentry */
-/* { dg-do compile } */
+/* { dg-do compile { target { *-*-linux* } } } */
/* { dg-options "-fprofile -mfentry" } */
/* { dg-final { scan-assembler "__fentry__" } } */
/* Origin: Andi Kleen */
--
ak@linux.intel.com -- Speaking for myself only.