aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorAndrew Pinski <andrew_pinski@playstation.sony.com>2007-05-26 03:29:58 +0000
committerAndrew Pinski <pinskia@gcc.gnu.org>2007-05-25 20:29:58 -0700
commit150594ba69066ade4b78e51d0a20ef9a16029bc2 (patch)
tree701640b5f9e9f9335a876008b9da83e849d8609b /gcc/testsuite
parentcd3a59b38ed5414f55606720817999b869e02762 (diff)
downloadgcc-150594ba69066ade4b78e51d0a20ef9a16029bc2.zip
gcc-150594ba69066ade4b78e51d0a20ef9a16029bc2.tar.gz
gcc-150594ba69066ade4b78e51d0a20ef9a16029bc2.tar.bz2
re PR tree-optimization/32090 (ICE in forwprop with zero sized array)
2007-05-25 Andrew Pinski <andrew_pinski@playstation.sony.com> PR tree-opt/32090 * tree-ssa-forwprop.c (forward_propagate_addr_into_variable_array_index): Remove the lhs argument. Use the type of def_rhs instead of lhs. (forward_propagate_addr_expr_1): Update use of forward_propagate_addr_into_variable_array_index. 2007-05-25 Andrew Pinski <andrew_pinski@playstation.sony.com> PR tree-opt/32090 * g++.dg/opt/array2.C: New testcase. From-SVN: r125087
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/g++.dg/opt/array2.C11
2 files changed, 16 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 59b1939..66ba361 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2007-05-25 Andrew Pinski <andrew_pinski@playstation.sony.com>
+
+ PR tree-opt/32090
+ * g++.dg/opt/array2.C: New testcase.
+
007-05-26 Uros Bizjak <ubizjak@gmail.com>
PR target/32065
diff --git a/gcc/testsuite/g++.dg/opt/array2.C b/gcc/testsuite/g++.dg/opt/array2.C
new file mode 100644
index 0000000..b40b052
--- /dev/null
+++ b/gcc/testsuite/g++.dg/opt/array2.C
@@ -0,0 +1,11 @@
+/* { dg-do compile } */
+/* { dg-options "-O2" } */
+struct JArray
+{
+ int data[1];
+};
+void *copyIntoByteArray (struct JArray *dest, __SIZE_TYPE__ offset)
+{
+ void *pdest = dest->data + offset;
+ return pdest;
+}