This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [committed] [wwwdocs] vectorizer webpage update


+        <li>Vectorization of fp/integer conversions of different
sizes (e.g. float/short)
+	    is soon to be committed to mainline.</li>

This still needs a bit of thought w.r.t to signed/unsigned types as
Richard pointed out [1]. As evident form the code he quoted, the
problem is with VEC_UNPACK_FLOAT_* that always expands as signed (due
to its FP output, where FP is considered as signed). IMO, unisnged_p
should be calculated from input operand for this case and
expand_widen_pattern_expr() should be reviewed and perhaps enhanced
for these operands.

Another issue was raised for the conversion itself. I think that we
don't need a full convert_optab here, as our conversion is severely
constrainted by current infrastructure allowing unpack of N-element
vector into 2*N/2 vectors only. Allowable conversions are then of

short -> float
unsigned short -> float
int -> double
unsigned int -> double

Conversion type (i.e. DFmode) by itself defines the only allowable
input type (i.e. SImode), where conversion signedness is defined from
its input operand. This is the reason, why full conversion optab would
be an overkill.

Similar rationale applies to float->int conversions, but the
signedness is defined by its output operand, as expected by expanders.



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]