[PATCH 1/2] Negative numbers added for sreal class.
authorMartin Liska <mliska@suse.cz>
Mon, 24 Nov 2014 10:41:18 +0000 (11:41 +0100)
committerMartin Liska <marxin@gcc.gnu.org>
Mon, 24 Nov 2014 10:41:18 +0000 (10:41 +0000)
commitfd27ffab14e3b7c131cc2e454edcd11c9cc53c2e
treefc054fc4a4670f251324a07ce04dee2b8dc12fa8
parent6a569cdda92269d42ae8e2cccd8c0f07d39b5d0c
[PATCH 1/2] Negative numbers added for sreal class.

* predict.c (propagate_freq): More elegant sreal API is used.
(estimate_bb_frequencies): Precomputed constants replaced by integer
constants.
* sreal.c (sreal::normalize): New function.
(sreal::to_int): Likewise.
(sreal::operator+): Likewise.
(sreal::operator-): Likewise.
(sreal::signedless_plus): Likewise.
(sreal::signedless_minus): Likewise.
(sreal::operator/): Negative number support is added.
* sreal.h: Definition of new functions added.
(inline sreal operator<<): New function.
(inline sreal operator>>): Likewise.

From-SVN: r218008
gcc/ChangeLog
gcc/predict.c
gcc/sreal.c
gcc/sreal.h