From: Richard Biener Date: Thu, 25 Jul 2019 06:57:46 +0000 (+0000) Subject: re PR tree-optimization/91236 (ICE in walk_non_aliased_vuses at gcc/tree-ssa-alias... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=599331c858294dec6ac94400e63d275c4836607f;p=gcc.git re PR tree-optimization/91236 (ICE in walk_non_aliased_vuses at gcc/tree-ssa-alias.c:3395 on aarch64) 2019-07-25 Richard Biener PR tree-optimization/91236 * tree-ssa-sccvn.c (vn_walk_cb_data::push_partial_def): Fix size of CONSTRUCTOR write. Fix buffer size we pass to native_encode_expr. From-SVN: r273787 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 45221a4a744..16757b046a4 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2019-07-25 Richard Biener + + PR tree-optimization/91236 + * tree-ssa-sccvn.c (vn_walk_cb_data::push_partial_def): Fix + size of CONSTRUCTOR write. Fix buffer size we pass to + native_encode_expr. + 2019-07-24 Jozef Lawrynowicz * config.gcc (msp430*-*-*): Fix non-GNU style in r273774. diff --git a/gcc/tree-ssa-sccvn.c b/gcc/tree-ssa-sccvn.c index 9369c36f50e..bafbea27241 100644 --- a/gcc/tree-ssa-sccvn.c +++ b/gcc/tree-ssa-sccvn.c @@ -1818,7 +1818,7 @@ vn_walk_cb_data::push_partial_def (const pd_data &pd, tree vuse, if (TREE_CODE (pd.rhs) == CONSTRUCTOR) /* Empty CONSTRUCTOR. */ memset (buffer + MAX (0, pd.offset), - 0, MIN ((HOST_WIDE_INT)sizeof (buffer), + 0, MIN ((HOST_WIDE_INT)sizeof (buffer) - MAX (0, pd.offset), pd.size + MIN (0, pd.offset))); else { @@ -1833,7 +1833,7 @@ vn_walk_cb_data::push_partial_def (const pd_data &pd, tree vuse, pad = GET_MODE_SIZE (mode) - pd.size; } len = native_encode_expr (pd.rhs, buffer + MAX (0, pd.offset), - sizeof (buffer - MAX (0, pd.offset)), + sizeof (buffer) - MAX (0, pd.offset), MAX (0, -pd.offset) + pad); if (len <= 0 || len < (pd.size - MAX (0, -pd.offset))) {