From f11b1f9d155bcbd797d0cb06bee2825c70ba9dd4 Mon Sep 17 00:00:00 2001 From: Olivier Hainque Date: Fri, 28 Feb 2020 10:57:20 +0000 Subject: [PATCH] Add dg-require-profiling directives to gcc.target/i386 tests This patch adds /* { dg-require-profiling "-pg" } */ to a few tests in gcc.target/i386 that use -pg explicitly, to prevent them from failing during runs for VxWorks targets. 2020-10-29 Olivier Hainque gcc/testsuite/ * gcc.target/i386/fentryname1.c: Add dg-require-profiling. * gcc.target/i386/fentryname2.c: Likewise. * gcc.target/i386/fentryname3.c: Likewise. * gcc.target/i386/returninst1.c: Likewise. * gcc.target/i386/returninst2.c: Likewise. * gcc.target/i386/returninst3.c: Likewise. --- gcc/testsuite/gcc.target/i386/fentryname1.c | 1 + gcc/testsuite/gcc.target/i386/fentryname2.c | 1 + gcc/testsuite/gcc.target/i386/fentryname3.c | 1 + gcc/testsuite/gcc.target/i386/returninst1.c | 1 + gcc/testsuite/gcc.target/i386/returninst2.c | 1 + gcc/testsuite/gcc.target/i386/returninst3.c | 1 + 6 files changed, 6 insertions(+) diff --git a/gcc/testsuite/gcc.target/i386/fentryname1.c b/gcc/testsuite/gcc.target/i386/fentryname1.c index 1265342b954..a9d1c727e86 100644 --- a/gcc/testsuite/gcc.target/i386/fentryname1.c +++ b/gcc/testsuite/gcc.target/i386/fentryname1.c @@ -1,5 +1,6 @@ /* { dg-do compile } */ /* { dg-require-effective-target mfentry } */ +/* { dg-require-profiling "-pg" } */ /* { dg-options "-pg -mfentry -mfentry-name=foo" } */ /* { dg-final { scan-assembler "call.*foo" } } */ /* { dg-final { scan-assembler "call.*bar" } } */ diff --git a/gcc/testsuite/gcc.target/i386/fentryname2.c b/gcc/testsuite/gcc.target/i386/fentryname2.c index c51c5d1ff71..13a43ec27e5 100644 --- a/gcc/testsuite/gcc.target/i386/fentryname2.c +++ b/gcc/testsuite/gcc.target/i386/fentryname2.c @@ -1,5 +1,6 @@ /* { dg-do compile } */ /* { dg-require-effective-target mfentry } */ +/* { dg-require-profiling "-pg" } */ /* { dg-options "-pg -mfentry -mrecord-mcount -mfentry-section=foo" } */ /* { dg-final { scan-assembler "section.*foo" } } */ /* { dg-final { scan-assembler "section.*bar" } } */ diff --git a/gcc/testsuite/gcc.target/i386/fentryname3.c b/gcc/testsuite/gcc.target/i386/fentryname3.c index 56881090a9c..bd7c997c178 100644 --- a/gcc/testsuite/gcc.target/i386/fentryname3.c +++ b/gcc/testsuite/gcc.target/i386/fentryname3.c @@ -1,5 +1,6 @@ /* { dg-do compile } */ /* { dg-require-effective-target mfentry } */ +/* { dg-require-profiling "-pg" } */ /* { dg-options "-pg -mfentry" } */ /* { dg-final { scan-assembler "section.*__entry_loc" } } */ /* { dg-final { scan-assembler "0x0f, 0x1f, 0x44, 0x00, 0x00" } } */ diff --git a/gcc/testsuite/gcc.target/i386/returninst1.c b/gcc/testsuite/gcc.target/i386/returninst1.c index 133fdeef5aa..74d10c925c3 100644 --- a/gcc/testsuite/gcc.target/i386/returninst1.c +++ b/gcc/testsuite/gcc.target/i386/returninst1.c @@ -1,5 +1,6 @@ /* { dg-do compile { target { ! ia32 } } } */ /* { dg-require-effective-target mfentry } */ +/* { dg-require-profiling "-pg" } */ /* { dg-options "-pg -mfentry -minstrument-return=call -mrecord-return" } */ /* { dg-final { scan-assembler "call.*__return__" } } */ /* { dg-final { scan-assembler "section.*return_loc" } } */ diff --git a/gcc/testsuite/gcc.target/i386/returninst2.c b/gcc/testsuite/gcc.target/i386/returninst2.c index 3629310a59a..e19f0d01f84 100644 --- a/gcc/testsuite/gcc.target/i386/returninst2.c +++ b/gcc/testsuite/gcc.target/i386/returninst2.c @@ -1,5 +1,6 @@ /* { dg-do compile { target { ! ia32 } } } */ /* { dg-require-effective-target mfentry } */ +/* { dg-require-profiling "-pg" } */ /* { dg-options "-pg -mfentry -minstrument-return=nop5 -mrecord-return" } */ /* { dg-final { scan-assembler-times "0x0f, 0x1f, 0x44, 0x00, 0x00" 3 } } */ /* { dg-final { scan-assembler "section.*return_loc" } } */ diff --git a/gcc/testsuite/gcc.target/i386/returninst3.c b/gcc/testsuite/gcc.target/i386/returninst3.c index b84cc77e12b..acb8984d38f 100644 --- a/gcc/testsuite/gcc.target/i386/returninst3.c +++ b/gcc/testsuite/gcc.target/i386/returninst3.c @@ -1,5 +1,6 @@ /* { dg-do compile { target { ! ia32 } } } */ /* { dg-require-effective-target mfentry } */ +/* { dg-require-profiling "-pg" } */ /* { dg-options "-pg -mfentry -minstrument-return=call" } */ /* { dg-final { scan-assembler-not "call.*__return__" } } */ -- 2.30.2