]> gcc.gnu.org Git - gcc.git/commit
objsz: Don't call replace_uses_by on SSA_NAME_OCCURS_IN_ABNORMAL_PHI [PR94423]
authorJakub Jelinek <jakub@redhat.com>
Tue, 7 Apr 2020 19:01:06 +0000 (21:01 +0200)
committerJakub Jelinek <jakub@redhat.com>
Thu, 17 Sep 2020 15:40:59 +0000 (17:40 +0200)
commit4cf91d649308d2130d891af451cc39b2822d41ee
tree10a4de767f5ea315789408529ef0339fcbb2b6a4
parent1d633231f0fff2a692e3991bcb7bb4d349c0c385
objsz: Don't call replace_uses_by on SSA_NAME_OCCURS_IN_ABNORMAL_PHI [PR94423]

The following testcase ICEs because the objsz pass calls replace_uses_by
on SSA_NAME_OCCURS_IN_ABNORMAL_PHI SSA_NAME.  The following patch instead
of that calls replace_call_with_value, which will turn it into
  xyz_123(ab) = 234;

2020-04-01  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/94423
* tree-object-size.c (pass_object_sizes::execute): Don't call
replace_uses_by for SSA_NAME_OCCURS_IN_ABNORMAL_PHI lhs, instead
call replace_call_with_value.

* gcc.dg/ubsan/pr94423.c: New test.

(cherry picked from commit 4486a537f14bc3b05ac552c3cbe18e540e397ed7)
gcc/testsuite/gcc.dg/ubsan/pr94423.c [new file with mode: 0644]
gcc/tree-object-size.c
This page took 0.065839 seconds and 6 git commands to generate.