ipa-utils.c (ipa_merge_profiles): Avoid ICE on mismatch in indirect edges.
authorJan Hubicka <hubicka@ucw.cz>
Wed, 21 Jan 2015 18:19:25 +0000 (19:19 +0100)
committerJan Hubicka <hubicka@gcc.gnu.org>
Wed, 21 Jan 2015 18:19:25 +0000 (18:19 +0000)
* ipa-utils.c (ipa_merge_profiles): Avoid ICE on mismatch in indirect
edges.

From-SVN: r219962

gcc/ChangeLog
gcc/ipa-utils.c

index 1c0a45e5e7ffe3be07f996045d418fe267392cee..4f3cc89fae61260c8aecca4478434cb6bfcec002 100644 (file)
@@ -1,3 +1,8 @@
+2015-01-21  Jan Hubicka  <hubicka@ucw.cz>
+
+       * ipa-utils.c (ipa_merge_profiles): Avoid ICE on mismatch in indirect
+       edges.
+
 2015-01-21  Bernd Edlinger  <bernd.edlinger@hotmail.de>
 
        * gimplify.c (gimplify_function_tree): Check the no_sanitize_thread
index 76125481cd9f9062e121bfc14823902522335f55..a8bb42d42639a21fca24336b3c7a6eff04dbeec6 100644 (file)
@@ -634,7 +634,7 @@ ipa_merge_profiles (struct cgraph_node *dst,
                   speculations when merging.  */
                gcc_unreachable ();
            }
-         else if (e2->speculative)
+         else if (e2 && e2->speculative)
            {
              cgraph_edge *direct, *indirect;
              ipa_ref *ref;