[ was: Re: [PATCH][committed][PR tree-optimization/82123] 02/06 Perform EVRP analysis in sprintf warning pass ]

On 02/20/2018 07:52 PM, Jeff Law wrote:
This twiddles one test -- adding the calls into the analyzer from the
sprintf pass causes us to record a range for an object that didn't have
one before and compromises the test.  I just turn off VRP  which is
sufficient to obscure things so that we don't remove the
__builtin_unreachable.


diff --git a/gcc/testsuite/gcc.dg/builtin-unreachable-6.c 
b/gcc/testsuite/gcc.dg/builtin-unreachable-6.c
index 1915dd1..b0504be 100644
--- a/gcc/testsuite/gcc.dg/builtin-unreachable-6.c
+++ b/gcc/testsuite/gcc.dg/builtin-unreachable-6.c
@@ -1,5 +1,5 @@
  /* { dg-do compile } */
-/* { dg-options "-O2 -fdump-tree-fab1 -fno-tree-dominator-opts" } */
+/* { dg-options "-O2 -fdump-tree-fab1 -fno-tree-dominator-opts -fno-tree-vrp" 
} */
void
  foo (int b, int c)


Preventing vrp triggered "sorry, unimplemented: target cannot support label values" on nvptx.

Fixed by requiring the effective target label_values.

Thanks,
- Tom
[testsuite] Require label_values in builtin-unreachable-6.c

2018-03-16  Tom de Vries  <t...@codesourcery.com>

	* gcc.dg/builtin-unreachable-6.c: Require effective target label_values.

---
 gcc/testsuite/gcc.dg/builtin-unreachable-6.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gcc/testsuite/gcc.dg/builtin-unreachable-6.c b/gcc/testsuite/gcc.dg/builtin-unreachable-6.c
index b0504be..4c3b9bb 100644
--- a/gcc/testsuite/gcc.dg/builtin-unreachable-6.c
+++ b/gcc/testsuite/gcc.dg/builtin-unreachable-6.c
@@ -1,5 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-tree-fab1 -fno-tree-dominator-opts -fno-tree-vrp" } */
+/* { dg-require-effective-target label_values } */
 
 void
 foo (int b, int c)

Reply via email to