This is the mail archive of the gcc-bugs@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]

[Bug tree-optimization/56488] [4.7 Regression] wrong code for loop at -O3


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56488

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> 2013-03-01 09:59:39 UTC ---
But e = e + 5 is avaluated as
e = (short) ((int) e + 5)
and thus I think it just falls down to implementation defined behavior
(assuming short is smaller than int of course), because no overflow happens in
the int type in which the addition is computed, and there is just cast of a
larger int value to smaller short type.


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