Commit 8bd7070a by Andreas Krebbel Committed by Andreas Krebbel

optabs.c (expand_atomic_compare_and_swap): Allow expander to fail.

2014-02-07  Andreas Krebbel  <Andreas.Krebbel@de.ibm.com>

	* optabs.c (expand_atomic_compare_and_swap): Allow expander to
	fail.

From-SVN: r207599
parent 831806cb
2014-02-07 Andreas Krebbel <Andreas.Krebbel@de.ibm.com>
* optabs.c (expand_atomic_compare_and_swap): Allow expander to
fail.
2014-02-07 Richard Biener <rguenther@suse.de>
PR middle-end/60092
......
......@@ -7383,12 +7383,13 @@ expand_atomic_compare_and_swap (rtx *ptarget_bool, rtx *ptarget_oval,
create_integer_operand (&ops[5], is_weak);
create_integer_operand (&ops[6], succ_model);
create_integer_operand (&ops[7], fail_model);
expand_insn (icode, 8, ops);
/* Return success/failure. */
target_bool = ops[0].value;
target_oval = ops[1].value;
goto success;
if (maybe_expand_insn (icode, 8, ops))
{
/* Return success/failure. */
target_bool = ops[0].value;
target_oval = ops[1].value;
goto success;
}
}
/* Otherwise fall back to the original __sync_val_compare_and_swap
......
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