Commit b418bc47 by Uros Bizjak

sync.md (atomic_compare_and_swap<dwi>_doubleword): Improve insn output code.

	* config/i386/sync.md (atomic_compare_and_swap<dwi>_doubleword):
	Improve insn output code.

From-SVN: r190861
parent eaf23fc3
...@@ -421,14 +421,13 @@ ...@@ -421,14 +421,13 @@
"TARGET_CMPXCHG<doublemodesuffix>B" "TARGET_CMPXCHG<doublemodesuffix>B"
{ {
bool swap = REGNO (operands[5]) != BX_REG; bool swap = REGNO (operands[5]) != BX_REG;
const char *xchg = "xchg{<imodesuffix>}\t%%<regprefix>bx, %5";
if (swap) if (swap)
output_asm_insn ("xchg{<imodesuffix>}\t%%<regprefix>bx, %5", operands); output_asm_insn (xchg, operands);
output_asm_insn ("lock{%;} %K7cmpxchg<doublemodesuffix>b\t%2", operands); output_asm_insn ("lock{%;} %K7cmpxchg<doublemodesuffix>b\t%2", operands);
if (swap) if (swap)
output_asm_insn ("xchg{<imodesuffix>}\t%%<regprefix>bx, %5", operands); output_asm_insn (xchg, operands);
return ""; return "";
}) })
......
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