This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PING] [PATCH] Add direct support for Linux kernel __fentry__ patching
- From: Andi Kleen <andi at firstfloor dot org>
- To: Dominique Dhumieres <dominiq at lps dot ens dot fr>
- Cc: andi at firstfloor dot org, law at redhat dot com, gcc-patches at gcc dot gnu dot org
- Date: Sat, 27 Sep 2014 17:35:47 +0200
- Subject: Re: [PING] [PATCH] Add direct support for Linux kernel __fentry__ patching
- Authentication-results: sourceware.org; auth=none
- References: <20140927112129 dot D8A9D100 at mailhost dot lps dot ens dot fr>
On Sat, Sep 27, 2014 at 01:21:29PM +0200, Dominique Dhumieres wrote:
> The new tests fail on darwin:
>
> /opt/gcc/work/gcc/testsuite/gcc.target/i386/nop-mcount.c:1:0: error: -mnop-mcount is not implemented for -fPIC
>
> and gcc.target/i386/record-mcount.c fails because mcount_loc is not found in the assembly.
Sorry. Here's a patch. I'll install it as obvious unless someone
complains. Also I hope it's the last mcount patch for now :-)
-Andi
diff --git a/gcc/testsuite/gcc.target/i386/nop-mcount.c b/gcc/testsuite/gcc.target/i386/nop-mcount.c
index 2592231..942cae0 100644
--- a/gcc/testsuite/gcc.target/i386/nop-mcount.c
+++ b/gcc/testsuite/gcc.target/i386/nop-mcount.c
@@ -1,5 +1,5 @@
/* Test -mnop-mcount */
-/* { dg-do compile } */
+/* { dg-do compile { target *-*-linux* } } */
/* { dg-options "-pg -mfentry -mrecord-mcount -mnop-mcount" } */
/* { dg-final { scan-assembler-not "__fentry__" } } */
/* Origin: Andi Kleen */
diff --git a/gcc/testsuite/gcc.target/i386/record-mcount.c b/gcc/testsuite/gcc.target/i386/record-mcount.c
index dae413e..26b0dbc 100644
--- a/gcc/testsuite/gcc.target/i386/record-mcount.c
+++ b/gcc/testsuite/gcc.target/i386/record-mcount.c
@@ -1,5 +1,5 @@
/* Test -mrecord-mcount */
-/* { dg-do compile } */
+/* { dg-do compile { target *-*-linux* } } */
/* { dg-options "-pg -mrecord-mcount" } */
/* { dg-final { scan-assembler "mcount_loc" } } */
/* Origin: Andi Kleen */