From 008c7367882c28ab07d39b3e914533cc6ca2256a Mon Sep 17 00:00:00 2001 From: Senthil Kumar Selvaraj Date: Tue, 23 May 2017 09:49:27 +0000 Subject: [PATCH] Fix bogus builtin-snprintf-warn-3.c failure for avr The test declares a struct with an array member that has INT_MAX/32767 elements. This causes a "type xxx is too large" error for targets like the avr, which has 16 bit pointers. Fix by marking the test as unsupported for targets with ptr size < 32. 2017-05-23 Senthil Kumar Selvaraj * gcc.dg/tree-ssa/builtin-snprintf-warn-3.c: Require ptr32plus. From-SVN: r248361 --- gcc/testsuite/ChangeLog | 4 ++++ gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-warn-3.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 702940b67df..5b6b82f8d96 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2017-05-23 Senthil Kumar Selvaraj + + * gcc.dg/tree-ssa/builtin-snprintf-warn-3.c: Require ptr32plus. + 2017-05-22 Michael Meissner PR target/80718 diff --git a/gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-warn-3.c b/gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-warn-3.c index 81c1d893e35..32c73d0edae 100644 --- a/gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-warn-3.c +++ b/gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-warn-3.c @@ -1,6 +1,7 @@ /* PR middle-end/79448 - unhelpful -Wformat-truncation=2 warning { dg-do compile } - { dg-options "-O2 -Wformat -Wformat-truncation=2 -ftrack-macro-expansion=0" } */ + { dg-options "-O2 -Wformat -Wformat-truncation=2 -ftrack-macro-expansion=0" } + { dg-require-effective-target ptr32plus } */ typedef __SIZE_TYPE__ size_t; typedef __WCHAR_TYPE__ wchar_t;