Hello!
We should always determine signedness of FIX_TRUNC_EXPR and derived
vectorized expressions based on the signedness of output operand.
Signendness of FLOAT_EXPR and derived vectorized expressions should be
determined based on the signedness of input operand.
Attached patch cleans this mess and fixes pr32216. Patch was
bootstrapped on i686-pc-linux-gnu, regression tested for all default
languages. OK for mainline?
2007-06-06 Uros Bizjak <ubizjak@gmail.com>
PR tree-optimization/32216
* tree-vectorizer.c (supportable_widening_operation): Determine
signedness of FIX_TRUNC_EXPR from output operand.
(supportable_narrowing_operation): Ditto.
* tree-vect-generic.c (expand_vector_operations_1): Determine
signedness of VEC_UNPACK_FLOAT_HI_EXPR and VEC_UNPACK_FLOAT_LO_EXPR
from input operand.
testsuite/ChangeLog:
2007-06-06 Uros Bizjak <ubizjak@gmail.com>
PR tree-optimization/32216
* gcc.dg/vect/pr32216.c: New test.
Uros.