From: rguenth Date: Mon, 5 Mar 2007 16:55:23 +0000 (+0000) Subject: 2007-03-05 Richard Guenther X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3857f443b888c32125e52a463ce44dd8eae3e97c;p=thirdparty%2Fgcc.git 2007-03-05 Richard Guenther PR tree-optimization/23777 * gcc.dg/tree-ssa/pr23777.c: New testcase. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@122558 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 84c2d2149651..70c78dc4d489 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2007-03-05 Richard Guenther + + PR tree-optimization/23777 + * gcc.dg/tree-ssa/pr23777.c: New testcase. + 2007-03-04 Manuel Lopez-Ibanez PR other/30465 diff --git a/gcc/testsuite/gcc.dg/tree-ssa/pr23777.c b/gcc/testsuite/gcc.dg/tree-ssa/pr23777.c new file mode 100644 index 000000000000..c2ad9b70707f --- /dev/null +++ b/gcc/testsuite/gcc.dg/tree-ssa/pr23777.c @@ -0,0 +1,19 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -fdump-tree-optimized" } */ + +extern void f(char *const *); +void g (char **o) +{ + static const char *const multilib_exclusions_raw[] = { 0 }; + const char *const *q = multilib_exclusions_raw; + + f (o); + while (*q++) + f (o); +} + +/* The last DCE pass is able to remove the load from + multilib_exclusions_raw. */ + +/* { dg-final { scan-tree-dump-not "multilib_exclusions_raw" "optimized" } } */ +/* { dg-final { cleanup-tree-dump "optimized" } } */