PR tree-optimization/94131 - ICE on printf with a VLA string and -fno-tree-ccp
authorMartin Sebor <msebor@redhat.com>
Wed, 25 Mar 2020 15:39:50 +0000 (09:39 -0600)
committerJeff Law <law@redhat.com>
Wed, 25 Mar 2020 15:39:50 +0000 (09:39 -0600)
commit05c13c439903eb78f109bcab62fd9a74f03a3c9b
tree96a1286aa6c51248a3e3c702fbaa3bba67522500
parent0fca105f8ca95747fad3d3315e642ea9dc6936e0
PR tree-optimization/94131 - ICE on printf with a VLA string and -fno-tree-ccp

gcc/testsuite/ChangeLog:

PR tree-optimization/94131
* gcc.dg/pr94131.c: New test.

gcc/ChangeLog:

PR tree-optimization/94131
* gimple-fold.c (get_range_strlen_tree): Fail for variable-length
types and decls.
* tree-ssa-strlen.c (get_range_strlen_dynamic): Avoid assuming
types have constant sizes.
gcc/ChangeLog
gcc/gimple-fold.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/pr84131.c [new file with mode: 0644]
gcc/tree-ssa-strlen.c