[PR103074] LRA: Check new conflicts when splitting hard reg live range.
authorVladimir N. Makarov <vmakarov@redhat.com>
Thu, 10 Mar 2022 21:16:00 +0000 (16:16 -0500)
committerVladimir N. Makarov <vmakarov@redhat.com>
Thu, 10 Mar 2022 21:16:49 +0000 (16:16 -0500)
commitd8e5fff6b74b82c2ac3254be9a1f0fb6b30dbdbf
treebc4d5745070d5f87cdc29d2a664d6613caf204e6
parentb5417a0ba7e26bec2abf05cad6c6ef840a9be41c
[PR103074] LRA: Check new conflicts when splitting hard reg live range.

Splitting hard register live range can create (artificial)
conflict of the hard register with another pseudo because of simplified
conflict calculation in LRA.  We should check such conflict on the next
assignment sub-pass and spill and reassign the pseudo if necessary.
The patch implements this.

gcc/ChangeLog:

PR target/103074
* lra-constraints.cc (split_reg): Set up
check_and_force_assignment_correctness_p when splitting hard
register live range.

gcc/testsuite/ChangeLog:

PR target/103074
* gcc.target/i386/pr103074.c: New.
gcc/lra-constraints.cc
gcc/testsuite/gcc.target/i386/pr103074.c [new file with mode: 0644]