gimple-fold.c (get_range_strlen): Only set *nonstr when an unterminated string is...
authorJeff Law <law@gcc.gnu.org>
Wed, 3 Oct 2018 17:23:15 +0000 (11:23 -0600)
committerJeff Law <law@gcc.gnu.org>
Wed, 3 Oct 2018 17:23:15 +0000 (11:23 -0600)
commit78125561e39be43dc140d5648abf402c4f7cf1c0
tree943f5b63b79fbb5461f5d36468ccd9ca70a4fb67
parent2e103ae2138ede8a4db831dea30065fe0041bc58
gimple-fold.c (get_range_strlen): Only set *nonstr when an unterminated string is discovered.

* gimple-fold.c (get_range_strlen): Only set *nonstr when
an unterminated string is discovered.  Bubble up range
even for unterminated strings.
(gimple_fold_builtin_strlen): Do not fold if get_range_strlen
indicates the string was not terminated via NONSTR.

From-SVN: r264816
gcc/ChangeLog
gcc/gimple-fold.c