Commit 70011923 by Ian Lance Taylor

Don't leave new_thread hanging if it was split by try_split

From-SVN: r4458
parent b4bf13a8
...@@ -3095,7 +3095,7 @@ fill_slots_from_thread (insn, condition, thread, opposite_thread, likely, ...@@ -3095,7 +3095,7 @@ fill_slots_from_thread (insn, condition, thread, opposite_thread, likely,
! stop_search_p (trial, ! thread_if_true) && (! lose || own_thread); ! stop_search_p (trial, ! thread_if_true) && (! lose || own_thread);
trial = next_nonnote_insn (trial)) trial = next_nonnote_insn (trial))
{ {
rtx pat; rtx pat, old_trial;
/* If we have passed a label, we no longer own this thread. */ /* If we have passed a label, we no longer own this thread. */
if (GET_CODE (trial) == CODE_LABEL) if (GET_CODE (trial) == CODE_LABEL)
...@@ -3142,7 +3142,10 @@ fill_slots_from_thread (insn, condition, thread, opposite_thread, likely, ...@@ -3142,7 +3142,10 @@ fill_slots_from_thread (insn, condition, thread, opposite_thread, likely,
|| (! insn_sets_resource_p (trial, &opposite_needed, 1) || (! insn_sets_resource_p (trial, &opposite_needed, 1)
&& ! may_trap_p (pat))) && ! may_trap_p (pat)))
{ {
old_trial = trial;
trial = try_split (pat, trial, 0); trial = try_split (pat, trial, 0);
if (new_thread == old_trial)
new_thread = trial;
pat = PATTERN (trial); pat = PATTERN (trial);
if (eligible_for_delay (insn, *pslots_filled, trial, flags)) if (eligible_for_delay (insn, *pslots_filled, trial, flags))
goto winner; goto winner;
...@@ -3156,7 +3159,10 @@ fill_slots_from_thread (insn, condition, thread, opposite_thread, likely, ...@@ -3156,7 +3159,10 @@ fill_slots_from_thread (insn, condition, thread, opposite_thread, likely,
#endif #endif
) )
{ {
old_trial = trial;
trial = try_split (pat, trial, 0); trial = try_split (pat, trial, 0);
if (new_thread == old_trial)
new_thread = trial;
pat = PATTERN (trial); pat = PATTERN (trial);
if ((thread_if_true if ((thread_if_true
? eligible_for_annul_false (insn, *pslots_filled, trial, flags) ? eligible_for_annul_false (insn, *pslots_filled, trial, flags)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment