This is the mail archive of the gcc-patches@gcc.gnu.org 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: [patch, tree-ssa] PR54295 Incorrect value extension in widening multiply-accumulate


On 17/08/12 18:05, Richard Earnshaw wrote:
Take two.

This version should address your concerns about handling

(u32)u16 * (u32)u16 -> u64

We now look at each operand directly, but when doing so we check whether
the operand is the same size as the result or not.  When it is, we can
strip any conversion; when it isn't the conversion must preserve
signedness of the inner operand and mustn't be a narrowing conversion.

So, if I understand correctly, this simply prevents it from stripping any conversions from the multiply's right-hand-side if they are not widening conversions?


That seems fine to me. Not that I have authority to approve it, of course.

Andrew


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