https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105458
--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Andrew Macleod <amacl...@gcc.gnu.org>: https://gcc.gnu.org/g:6101a276c34b94f692206739d98aa7faf2e7b2ad commit r13-564-g6101a276c34b94f692206739d98aa7faf2e7b2ad Author: Andrew MacLeod <amacl...@redhat.com> Date: Mon May 16 21:39:30 2022 -0400 Check for equivalence after merging relations. When registering a relation, we need to merge with any existing relation before checking if it was an equivalence... otherwise it was not being handled properly. gcc/ PR tree-optimization/105458 * value-relation.cc (path_oracle::register_relation): Merge, then check for equivalence. gcc/testsuite/ * gcc.dg/pr105458.c: New.