aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-phiopt.cc
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2022-12-22 12:44:13 +0100
committerJakub Jelinek <jakub@redhat.com>2022-12-22 12:44:13 +0100
commit0cb5d7cdbab8e5f8359764ef5f62d93c2bc88552 (patch)
tree622e6f49f7d78a8b4ec2c947f53bf04a0783ce9b /gcc/tree-ssa-phiopt.cc
parent7b2cf5041460859ca4f58e5da1308b7ef9129d8b (diff)
downloadgcc-0cb5d7cdbab8e5f8359764ef5f62d93c2bc88552.zip
gcc-0cb5d7cdbab8e5f8359764ef5f62d93c2bc88552.tar.gz
gcc-0cb5d7cdbab8e5f8359764ef5f62d93c2bc88552.tar.bz2
cse: Fix up CSE const_anchor handling [PR108193]
The following testcase ICEs on aarch64, because insert_const_anchor inserts invalid CONST_INT into the CSE tables - 0x80000000 for SImode. The second hunk of the patch fixes that, the first one is to avoid triggering undefined behavior at compile time during compute_const_anchors computations - performing those additions and subtractions in HOST_WIDE_INT means it can overflow for certain constants. 2022-12-22 Jakub Jelinek <jakub@redhat.com> PR rtl-optimization/108193 * cse.cc (compute_const_anchors): Change n type to unsigned HOST_WIDE_INT, adjust comparison against it to avoid warnings. Formatting fix. (insert_const_anchor): Use gen_int_mode instead of GEN_INT. * gfortran.dg/pr108193.f90: New test.
Diffstat (limited to 'gcc/tree-ssa-phiopt.cc')
0 files changed, 0 insertions, 0 deletions