Commit 41c3713a by Nathan Sidwell Committed by Nathan Sidwell

nvptx.md (atomic_compare_and_swap<mode>): Use sel_truesi, not andsi.

	* config/nvptx/nvptx.md (atomic_compare_and_swap<mode>): Use
	sel_truesi, not andsi.

From-SVN: r227587
parent 956db28e
2015-09-09 Nathan Sidwell <nathan@acm.org>
* config/nvptx/nvptx.md (atomic_compare_and_swap<mode>): Use
sel_truesi, not andsi.
2015-09-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com> 2015-09-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
* config/arm/arm.md (*subsi3_compare0): Rename to... * config/arm/arm.md (*subsi3_compare0): Rename to...
......
...@@ -1351,14 +1351,12 @@ ...@@ -1351,14 +1351,12 @@
(match_operand:SI 7 "const_int_operand")] ;; failure model (match_operand:SI 7 "const_int_operand")] ;; failure model
"" ""
{ {
emit_insn (gen_atomic_compare_and_swap<mode>_1 (operands[1], operands[2], operands[3], emit_insn (gen_atomic_compare_and_swap<mode>_1
operands[4], operands[6])); (operands[1], operands[2], operands[3], operands[4], operands[6]));
rtx tmp = gen_reg_rtx (GET_MODE (operands[0])); rtx cond = gen_reg_rtx (BImode);
emit_insn (gen_cstore<mode>4 (tmp, emit_move_insn (cond, gen_rtx_EQ (BImode, operands[1], operands[3]));
gen_rtx_EQ (SImode, operands[1], operands[3]), emit_insn (gen_sel_truesi (operands[0], cond, GEN_INT (1), GEN_INT (0)));
operands[1], operands[3]));
emit_insn (gen_andsi3 (operands[0], tmp, GEN_INT (1)));
DONE; DONE;
}) })
......
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