Hi Richard,

I have here part 1 of this patch, which does not use undefined behaviour.

Currently I start to think that also TYPE_SATURATING just cannot happen
here, because only some targets have saturating types, for instance ARM,
and also for those who have it, it is only allowed with fixed point types.
Thus _Sat is only allowed with _Frac or _Accum. I have not seen anything
different, for instance a vector, with saturation yet.


OK for trunk after boot-strap & regression-test?


Thanks
Bernd.
                                          
gcc/ChangeLog:
2014-06-24  Bernd Edlinger  <bernd.edlin...@hotmail.de>

        * tree-ssa-forwprop.c (associate_plusminus): Do not use the
        transformation (T)(P + A) - (T)P -> (T)A with widening integer
        conversions.

testsuite/ChangeLog:
2014-06-24  Bernd Edlinger  <bernd.edlin...@hotmail.de>

        * gcc.c-torture/execute/20140622-1.c: New test.


Attachment: patch-forwprop.diff
Description: Binary data

Reply via email to