From: Richard Guenther Date: Thu, 15 May 2008 14:09:11 +0000 (+0000) Subject: re PR tree-optimization/36245 (internal compiler error: in build2_stat, at tree.c... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=41d1c8ddaf0e1a76896a7e0101b8f3bb5eb4bd8e;p=gcc.git re PR tree-optimization/36245 (internal compiler error: in build2_stat, at tree.c:3116) 2008-05-15 Richard Guenther PR tree-optimization/36245 * tree-ssa-address.c (add_to_parts): Deal with non-pointer bases. * gcc.c-torture/compile/pr36245.c: New testcase. From-SVN: r135361 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index c2af14e25bd..fae0f99623b 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2008-05-15 Richard Guenther + + PR tree-optimization/36245 + * gcc.c-torture/compile/pr36245.c: New testcase. + 2008-05-15 Richard Guenther * gcc.dg/tree-ssa/loadpre7.c: Adjust scan for not performed diff --git a/gcc/testsuite/gcc.c-torture/compile/pr36245.c b/gcc/testsuite/gcc.c-torture/compile/pr36245.c new file mode 100644 index 00000000000..37598753950 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr36245.c @@ -0,0 +1,21 @@ +extern char buf1[10]; +extern char buf2[10]; +extern void b(int i, int j, int w); + +void a() { + int i,j; + char *p; + int w; + + p = buf1; + for(j = 0;j < 10; j++) { + for(i = 0;i < 10; i++) { + w = *p; + if(w != 1) { + w = buf2[p - buf1]; + b(i*2+1, j, w); + } + p++; + } + } +}