https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83296
--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> --- Author: rguenth Date: Thu Dec 7 13:21:51 2017 New Revision: 255466 URL: https://gcc.gnu.org/viewcvs?rev=255466&root=gcc&view=rev Log: 2017-12-07 Richard Biener <rguent...@suse.de> PR tree-optimization/83296 PR tree-optimization/67769 * tree-ssa-phiopt.c (conditional_replacement): Do not reset flow sensitive info in an unrelated BB. (value_replacement): Use reset_flow_sensitive_info. (minmax_replacement): Reset flow sensitive info on the def we move. Do not reset flow sensitive info in the whole BB we move the stmt to. (abs_replacement): Likewise. * g++.dg/warn/Wstringop-overflow-1.C: New testcase. Added: trunk/gcc/testsuite/g++.dg/warn/Wstringop-overflow-1.C Modified: trunk/gcc/ChangeLog trunk/gcc/testsuite/ChangeLog trunk/gcc/tree-ssa-phiopt.c