aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitar Dimitrov <dimitar@dinux.eu>2024-10-24 19:59:42 +0300
committerDimitar Dimitrov <dimitar@dinux.eu>2024-10-24 20:14:10 +0300
commitbcd56224d74cdd8dc3c77097de51e97bc7b6d181 (patch)
treefe29ce128f73ef816682d4dfa5f413f647a2f3be
parent0dbc588acaa27a3a56bc9173bd577e1293f10046 (diff)
downloadgcc-bcd56224d74cdd8dc3c77097de51e97bc7b6d181.zip
gcc-bcd56224d74cdd8dc3c77097de51e97bc7b6d181.tar.gz
gcc-bcd56224d74cdd8dc3c77097de51e97bc7b6d181.tar.bz2
testsuite: Require effective target pie for pr113197
The test for PR113197 explicitly enables PIE. But targets without PIE emit warnings when -fpie is passed (e.g. pru and avr), which causes the test to fail. Fix by adding an effective target requirement for PIE. With this patch, the test now is marked as unsupported for pru-unknown-elf. Testing for x86_64-pc-linux-gnu passes with current mainline, and fails if the fix from r15-4018-g02f4efe3c12cf7 is reverted. PR ipa/113197 gcc/testsuite/ChangeLog: * gcc.dg/lto/pr113197_0.c: Require effective target pie. Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu>
-rw-r--r--gcc/testsuite/gcc.dg/lto/pr113197_0.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/lto/pr113197_0.c b/gcc/testsuite/gcc.dg/lto/pr113197_0.c
index 293c820..6fd8624 100644
--- a/gcc/testsuite/gcc.dg/lto/pr113197_0.c
+++ b/gcc/testsuite/gcc.dg/lto/pr113197_0.c
@@ -1,4 +1,5 @@
/* { dg-lto-do link } */
+/* { dg-require-effective-target pie } */
/* { dg-lto-options { { -O -flto -fpie } } } */
/* { dg-extra-ld-options { -r -nostdlib -flinker-output=nolto-rel } } */