[Bug tree-optimization/56478] [4.8 Regression] ICE: Floating point exception in tree_estimate_probability

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Thu Feb 28 08:05:00 GMT 2013


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.



More information about the Gcc-bugs mailing list