]> git.ipfire.org Git - thirdparty/gcc.git/commit
Maintain complex constraint vector order during PTA solving
authorRichard Biener <rguenther@suse.de>
Tue, 23 Jul 2024 12:05:47 +0000 (14:05 +0200)
committerRichard Biener <rguenth@gcc.gnu.org>
Thu, 25 Jul 2024 06:37:36 +0000 (08:37 +0200)
commit09de976f9bcab1d3018d5461ea2abb8a47f20528
treec594843bf5bea50cf96e2be227f9cb873daf5155
parentbc00de070f0b9a25f68ffddbefe516543a44bd23
Maintain complex constraint vector order during PTA solving

There's a FIXME comment in the PTA constraint solver that the vector
of complex constraints can get unsorted which can lead to duplicate
entries piling up during node unification.  The following fixes this
with the assumption that delayed updates to constraints are uncommon
(otherwise re-sorting the whole vector would be more efficient).

* tree-ssa-structalias.cc (constraint_equal): Take const
reference to constraints.
(constraint_vec_find): Similar.
(solve_graph): Keep constraint vector sorted and verify
sorting with checking.
gcc/tree-ssa-structalias.cc