]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Check is_single_const in intersect_with_plats
authorMartin Jambor <mjambor@suse.cz>
Thu, 17 May 2018 12:23:34 +0000 (14:23 +0200)
committerMartin Jambor <jamborm@gcc.gnu.org>
Thu, 17 May 2018 12:23:34 +0000 (14:23 +0200)
2018-05-17  Martin Jambor  <mjambor@suse.cz>

Backport from mainline
2018-05-11  Martin Jambor  <mjambor@suse.cz>

PR ipa/85655
* ipa-cp.c (intersect_with_plats): Check that the lattice contains
single const.

From-SVN: r260320

gcc/ChangeLog
gcc/ipa-cp.c

index 12413cc3c3cf684db49712c1bf0eb3af710fbe80..c55b24017f422e35676bd7867a0aedd3bca1dbe2 100644 (file)
@@ -1,3 +1,12 @@
+2018-05-17  Martin Jambor  <mjambor@suse.cz>
+
+       Backport from mainline
+       2018-05-11  Martin Jambor  <mjambor@suse.cz>
+
+       PR ipa/85655
+       * ipa-cp.c (intersect_with_plats): Check that the lattice contains
+       single const.
+
 2018-05-01  Tom de Vries  <tom@codesourcery.com>
 
        backport from trunk:
index f5dcfc0341bc06a36d1a1defc00be9de265f25f1..3902d3a8a006827496c70a8e2e5b8146669d8bfe 100644 (file)
@@ -4027,7 +4027,9 @@ intersect_with_plats (struct ipcp_param_lattices *plats,
          if (aglat->offset - offset == item->offset)
            {
              gcc_checking_assert (item->value);
-             if (values_equal_for_ipcp_p (item->value, aglat->values->value))
+             if (aglat->is_single_const ()
+                 && values_equal_for_ipcp_p (item->value,
+                                             aglat->values->value))
                found = true;
              break;
            }