aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-strlen.c
diff options
context:
space:
mode:
authorMartin Sebor <msebor@redhat.com>2018-02-14 23:22:15 +0000
committerMartin Sebor <msebor@gcc.gnu.org>2018-02-14 16:22:15 -0700
commit816fad6ed44fb327c4034c40eb9d2bccafd6538d (patch)
tree4abe2f0ee56e212baf1980d760fbb71436a2cbfb /gcc/tree-ssa-strlen.c
parent7c102986d6f8205ebc3952344c64edbcd7018fbc (diff)
downloadgcc-816fad6ed44fb327c4034c40eb9d2bccafd6538d.zip
gcc-816fad6ed44fb327c4034c40eb9d2bccafd6538d.tar.gz
gcc-816fad6ed44fb327c4034c40eb9d2bccafd6538d.tar.bz2
PR tree-optimization/83698 - bogus offset in -Wrestrict messages for strcat of unknown strings
gcc/ChangeLog: PR tree-optimization/83698 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For arrays constrain the offset range to their bounds. (builtin_access::strcat_overlap): Adjust the bounds of overlap offset. (builtin_access::overlap): Avoid setting the size of overlap if it's already been set. (maybe_diag_overlap): Also consider arrays when deciding what values of offsets to include in diagnostics. gcc/testsuite/ChangeLog: PR tree-optimization/83698 * gcc.dg/Wrestrict-7.c: New test. * c-c++-common/Wrestrict.c: Adjust expected values for strcat. * gcc.target/i386/chkp-stropt-17.c: Same. From-SVN: r257676
Diffstat (limited to 'gcc/tree-ssa-strlen.c')
0 files changed, 0 insertions, 0 deletions