From: Martin Sebor Date: Mon, 17 Dec 2018 18:10:58 +0000 (+0000) Subject: builtin-snprintf-4.c: Adjust for ILP32. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=22b04f05ab8e05707a031a5b6dfc1eb72d056957;p=gcc.git builtin-snprintf-4.c: Adjust for ILP32. gcc/testsuite/ChangeLog: * gcc.dg/tree-ssa/builtin-snprintf-4.c: Adjust for ILP32. From-SVN: r267206 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 8ba858b5177..220828db3b4 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2018-12-17 Martin Sebor + + * gcc.dg/tree-ssa/builtin-snprintf-4.c: Adjust for ILP32. + 2018-12-17 Senthil Kumar Selvaraj PR rtl-optimization/88253 diff --git a/gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-4.c b/gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-4.c index 5a6160881e3..97a385e581d 100644 --- a/gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-4.c +++ b/gcc/testsuite/gcc.dg/tree-ssa/builtin-snprintf-4.c @@ -58,7 +58,12 @@ extern void sink (int, ...); static const size_t imax = __INT_MAX__; static const size_t imaxp1 = imax + 1; +#if __PTRDIFF_MAX__ == __INT_MAX__ +/* Make the test pass on ILP32 the same way it does on LP64. */ +static const size_t dmax = __PTRDIFF_MAX__ + (size_t)1; +#else static const size_t dmax = __PTRDIFF_MAX__; +#endif static const size_t dmaxp1 = dmax + 1; static const size_t szmax = __SIZE_MAX__;