+2017-11-14 Jan Hubicka <hubicka@ucw.cz>
+
+ * cfg.c (scale_bbs_frequencies_int,
+ cale_bbs_frequencies_gcov_type): Remove.
+ * cfg.h (scale_bbs_frequencies_int,
+ cale_bbs_frequencies_gcov_type): Remove.
+
2017-11-14 Jan Hubicka <hubicka@ucw.cz>
* tree-ssa-loop-manip.c
gcc_assert (bb == taken_edge->src);
}
-/* Multiply all frequencies of basic blocks in array BBS of length NBBS
- by NUM/DEN, in int arithmetic. May lose some accuracy. */
-void
-scale_bbs_frequencies_int (basic_block *bbs, int nbbs, int num, int den)
-{
- int i;
- if (num < 0)
- num = 0;
-
- /* Scale NUM and DEN to avoid overflows. Frequencies are in order of
- 10^4, if we make DEN <= 10^3, we can afford to upscale by 100
- and still safely fit in int during calculations. */
- if (den > 1000)
- {
- if (num > 1000000)
- return;
-
- num = RDIV (1000 * num, den);
- den = 1000;
- }
- if (num > 100 * den)
- return;
-
- for (i = 0; i < nbbs; i++)
- {
- bbs[i]->count = bbs[i]->count.apply_scale (num, den);
- }
-}
-
-/* Multiply all frequencies of basic blocks in array BBS of length NBBS
- by NUM/DEN, in gcov_type arithmetic. More accurate than previous
- function but considerably slower. */
-void
-scale_bbs_frequencies_gcov_type (basic_block *bbs, int nbbs, gcov_type num,
- gcov_type den)
-{
- int i;
-
- for (i = 0; i < nbbs; i++)
- bbs[i]->count = bbs[i]->count.apply_scale (num, den);
-}
-
/* Multiply all frequencies of basic blocks in array BBS of length NBBS
by NUM/DEN, in profile_count arithmetic. More accurate than previous
function but considerably slower. */
extern void dump_bb_info (FILE *, basic_block, int, dump_flags_t, bool, bool);
extern void brief_dump_cfg (FILE *, dump_flags_t);
extern void update_bb_profile_for_threading (basic_block, profile_count, edge);
-extern void scale_bbs_frequencies_int (basic_block *, int, int, int);
-extern void scale_bbs_frequencies_gcov_type (basic_block *, int, gcov_type,
- gcov_type);
extern void scale_bbs_frequencies_profile_count (basic_block *, int,
profile_count, profile_count);
extern void scale_bbs_frequencies (basic_block *, int, profile_probability);