[rtl, i386] vec_merge simplification
Eric Botcazou
ebotcazou@adacore.com
Tue Apr 2 08:56:00 GMT 2013
> Thanks, here is a version taking into account all your comments, and which
> still passes bootstrap+testsuite on x86_64-linux-gnu. I am not completely
> sure if there is a point checking !side_effects_p (op1) after rtx_equal_p
> (op0, op1), but I am still doing it as it seems safe.
It's also done in other cases (IOR, XOR, AND, etc) where we return the first
operand after having found out that the second operand is equal to it. If the
semantics of VEC_MERGE is to evaluate its operands, then they always need to
be evaluated, whatever the result.
> gcc/
> * simplify-rtx.c (simplify_binary_operation_1) <VEC_SELECT>:
> Handle VEC_MERGE.
> (simplify_ternary_operation) <VEC_MERGE>: Use unsigned HOST_WIDE_INT
> for masks. Test for side effects. Handle nested VEC_MERGE. Handle
> equal arguments.
OK for mainline, thanks.
--
Eric Botcazou
More information about the Gcc-patches
mailing list