From 97b8f8679d0db4b9159e1640ff34460aaccace74 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Tue, 25 Sep 2018 13:51:45 +0000 Subject: [PATCH] i386: Compile pr82699-5.c and pr82699-6.c with -fno-pic Compile pr82699-5.c and pr82699-6.c with -fno-pic to avoid FAIL: gcc.target/i386/pr82699-5.c (test for excess errors) Excess errors: cc1: sorry, unimplemented: -mfentry isn't supported for 32-bit in combination with -fpic FAIL: gcc.target/i386/pr82699-6.c (test for excess errors) Excess errors: cc1: error: -mnop-mcount is not implemented for -fPIC cc1: sorry, unimplemented: -mfentry isn't supported for 32-bit in combination with -fpic when running GCC testsuite with --target_board='unix{-fpic\ -m32,-fpic}'. PR target/82699 * gcc.target/i386/pr82699-5.c: Add -fno-pic for ia32. * gcc.target/i386/pr82699-6.c: Add -fno-pic. From-SVN: r264569 --- gcc/testsuite/ChangeLog | 6 ++++++ gcc/testsuite/gcc.target/i386/pr82699-5.c | 1 + gcc/testsuite/gcc.target/i386/pr82699-6.c | 2 +- 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 9d3770344d5..4a591bf07ff 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2018-09-25 H.J. Lu + + PR target/82699 + * gcc.target/i386/pr82699-5.c: Add -fno-pic for ia32. + * gcc.target/i386/pr82699-6.c: Add -fno-pic. + 2018-09-25 Jakub Jelinek * gfortran.dg/coarray_lock_7.f90: Adjust scan-tree-dump-times for diff --git a/gcc/testsuite/gcc.target/i386/pr82699-5.c b/gcc/testsuite/gcc.target/i386/pr82699-5.c index e0fe0188d56..0c547e25f03 100644 --- a/gcc/testsuite/gcc.target/i386/pr82699-5.c +++ b/gcc/testsuite/gcc.target/i386/pr82699-5.c @@ -1,5 +1,6 @@ /* { dg-do compile { target *-*-linux* } } */ /* { dg-options "-O2 -fcf-protection -mfentry -fasynchronous-unwind-tables" } */ +/* { dg-additional-options "-fno-pic" { target ia32 } } */ /* { dg-final { scan-assembler-times {\t\.cfi_startproc\n\tendbr} 1 } } */ extern int bar (int); diff --git a/gcc/testsuite/gcc.target/i386/pr82699-6.c b/gcc/testsuite/gcc.target/i386/pr82699-6.c index cacf0ab3db2..ff6bae7d1ea 100644 --- a/gcc/testsuite/gcc.target/i386/pr82699-6.c +++ b/gcc/testsuite/gcc.target/i386/pr82699-6.c @@ -1,5 +1,5 @@ /* { dg-do compile { target *-*-linux* } } */ -/* { dg-options "-O2 -fcf-protection -pg -mfentry -mrecord-mcount -mnop-mcount -fasynchronous-unwind-tables" } */ +/* { dg-options "-fno-pic -O2 -fcf-protection -pg -mfentry -mrecord-mcount -mnop-mcount -fasynchronous-unwind-tables" } */ /* { dg-final { scan-assembler-times {\t\.cfi_startproc\n\tendbr} 1 } } */ extern int bar (int); -- 2.30.2