H. J. Lu wrote:
__builtin_ia32_vec_set_v2di will be expanded to [(set (match_operand:V2DI 0 "register_operand" "=x") (vec_merge:V2DI (vec_duplicate:V2DI (match_operand:DI 2 "nonimmediate_operand" "rm")) (match_operand:V2DI 1 "register_operand" "0") (match_operand:SI 3 "const_pow2_1_to_2_operand" "n")))]
Named rtl expanders aren't allowed to clobber their inputs. You will need to generate a pseudo-reg temp in the expander, copy the first input to the temp, and then use the temp as the output/input argument.
There are probably lots of existing examples in the i386 *.md files to look at. See for instance the reduc_splus_v4sf pattern in the sse.md file.
-- Jim Wilson, GNU Tools Support, http://www.specifix.com