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/56478] [4.8 Regression] ICE: Floating point exception in tree_estimate_probability


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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dehao at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> 2013-02-28 08:05:03 UTC ---
loop_bound = compare_bound = 0
base = -9223372036854775808
so
HOST_WIDE_INT loop_count = (loop_bound - base) / compare_step;
first invokes undefined behavior (loop_bound - base) computation and then
-LONG_LONG_MIN / -1 SIGFPEs.
That and the following code is just full of many potential undefined behaviors.
Even the compare_count++ or loop_count++ could trigger that.


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