* since string insns cannot override the destination segment. */
if ((TARGET_SINGLE_STRINGOP || optimize_insn_for_size_p ())
&& !(fixed_regs[SI_REG] || fixed_regs[DI_REG])
- && ADDR_SPACE_GENERIC_P (MEM_ADDR_SPACE (operands[1])))
+ && ADDR_SPACE_GENERIC_P (MEM_ADDR_SPACE (operands[1]))
+ && (ADDR_SPACE_GENERIC_P (MEM_ADDR_SPACE (operands[3]))
+ || Pmode == word_mode))
{
emit_insn (gen_strmov_singleop (operands[0], operands[1],
operands[2], operands[3],
(const_int 8)))]
"TARGET_64BIT
&& !(fixed_regs[SI_REG] || fixed_regs[DI_REG])
- && ADDR_SPACE_GENERIC_P
- (MEM_ADDR_SPACE (SET_DEST (XVECEXP (PATTERN (insn), 0, 0))))"
+ && ix86_check_movs (insn, 0)"
{
rtx exp = XVECEXP (PATTERN (insn), 0, 0);
operands[0] = SET_DEST (exp);
operands[1] = SET_SRC (exp);
- return "%^movsq\t{%1, %0|%0, %1}";
+ return "movsq\t{%1, %0|%0, %1}";
}
[(set_attr "type" "str")
(set_attr "memory" "both")
(plus:P (match_dup 3)
(const_int 4)))]
"!(fixed_regs[SI_REG] || fixed_regs[DI_REG])
- && ADDR_SPACE_GENERIC_P
- (MEM_ADDR_SPACE (SET_DEST (XVECEXP (PATTERN (insn), 0, 0))))"
+ && ix86_check_movs (insn, 0)"
{
rtx exp = XVECEXP (PATTERN (insn), 0, 0);
operands[0] = SET_DEST (exp);
operands[1] = SET_SRC (exp);
- return "%^movs{l|d}\t{%1, %0|%0, %1}";
+ return "movs{l|d}\t{%1, %0|%0, %1}";
}
[(set_attr "type" "str")
(set_attr "memory" "both")
(plus:P (match_dup 3)
(const_int 2)))]
"!(fixed_regs[SI_REG] || fixed_regs[DI_REG])
- && ADDR_SPACE_GENERIC_P
- (MEM_ADDR_SPACE (SET_DEST (XVECEXP (PATTERN (insn), 0, 0))))"
+ && ix86_check_movs (insn, 0)"
{
rtx exp = XVECEXP (PATTERN (insn), 0, 0);
operands[0] = SET_DEST (exp);
operands[1] = SET_SRC (exp);
- return "%^movsw\t{%1, %0|%0, %1}";
+ return "movsw\t{%1, %0|%0, %1}";
}
[(set_attr "type" "str")
(set_attr "memory" "both")
(plus:P (match_dup 3)
(const_int 1)))]
"!(fixed_regs[SI_REG] || fixed_regs[DI_REG])
- && ADDR_SPACE_GENERIC_P
- (MEM_ADDR_SPACE (SET_DEST (XVECEXP (PATTERN (insn), 0, 0))))"
+ && ix86_check_movs (insn, 0)"
{
rtx exp = XVECEXP (PATTERN (insn), 0, 0);
operands[0] = SET_DEST (exp);
operands[1] = SET_SRC (exp);
- return "%^movsb\t{%1, %0|%0, %1}";
+ return "movsb\t{%1, %0|%0, %1}";
}
[(set_attr "type" "str")
(set_attr "memory" "both")
(use (match_dup 5))]
"TARGET_64BIT
&& !(fixed_regs[CX_REG] || fixed_regs[SI_REG] || fixed_regs[DI_REG])
- && ADDR_SPACE_GENERIC_P
- (MEM_ADDR_SPACE (SET_DEST (XVECEXP (PATTERN (insn), 0, 3))))"
+ && ix86_check_movs (insn, 3)"
{
rtx exp = XVECEXP (PATTERN (insn), 0, 3);
operands[0] = SET_DEST (exp);
operands[1] = SET_SRC (exp);
- return "%^rep{%;} movsq\t{%1, %0|%0, %1}";
+ return "rep{%;} movsq\t{%1, %0|%0, %1}";
}
[(set_attr "type" "str")
(set_attr "prefix_rep" "1")
(mem:BLK (match_dup 4)))
(use (match_dup 5))]
"!(fixed_regs[CX_REG] || fixed_regs[SI_REG] || fixed_regs[DI_REG])
- && ADDR_SPACE_GENERIC_P
- (MEM_ADDR_SPACE (SET_DEST (XVECEXP (PATTERN (insn), 0, 3))))"
+ && ix86_check_movs (insn, 3)"
{
rtx exp = XVECEXP (PATTERN (insn), 0, 3);
operands[0] = SET_DEST (exp);
operands[1] = SET_SRC (exp);
- return "%^rep{%;} movs{l|d}\t{%1, %0|%0, %1}";
+ return "rep{%;} movs{l|d}\t{%1, %0|%0, %1}";
}
[(set_attr "type" "str")
(set_attr "prefix_rep" "1")
(mem:BLK (match_dup 4)))
(use (match_dup 5))]
"!(fixed_regs[CX_REG] || fixed_regs[SI_REG] || fixed_regs[DI_REG])
- && ADDR_SPACE_GENERIC_P
- (MEM_ADDR_SPACE (SET_DEST (XVECEXP (PATTERN (insn), 0, 3))))"
+ && ix86_check_movs (insn, 3)"
{
rtx exp = XVECEXP (PATTERN (insn), 0, 3);
operands[0] = SET_DEST (exp);
operands[1] = SET_SRC (exp);
- return "%^rep{%;} movsb\t{%1, %0|%0, %1}";
+ return "rep{%;} movsb\t{%1, %0|%0, %1}";
}
[(set_attr "type" "str")
(set_attr "prefix_rep" "1")