]>
Commit | Line | Data |
---|---|---|
3aa71f9d L |
1 | /* Header file for minimum-cost maximal flow routines used to smooth basic |
2 | block and edge frequency counts. | |
d1e082c2 | 3 | Copyright (C) 2008-2013 Free Software Foundation, Inc. |
3aa71f9d L |
4 | Contributed by Paul Yuan (yingbo.com@gmail.com) |
5 | and Vinodha Ramasamy (vinodha@google.com). | |
6 | ||
7 | This file is part of GCC. | |
8 | GCC is free software; you can redistribute it and/or modify it under | |
9 | the terms of the GNU General Public License as published by the Free | |
10 | Software Foundation; either version 3, or (at your option) any later | |
11 | version. | |
12 | ||
13 | GCC is distributed in the hope that it will be useful, but WITHOUT ANY | |
14 | WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
15 | FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
16 | for more details. | |
17 | ||
18 | You should have received a copy of the GNU General Public License | |
19 | along with GCC; see the file COPYING3. If not see | |
20 | <http://www.gnu.org/licenses/>. */ | |
21 | ||
22 | #ifndef PROFILE_H | |
23 | #define PROFILE_H | |
24 | ||
25 | /* Additional information about edges. */ | |
26 | struct edge_info | |
27 | { | |
28 | unsigned int count_valid:1; | |
29 | ||
30 | /* Is on the spanning tree. */ | |
31 | unsigned int on_tree:1; | |
32 | ||
33 | /* Pretend this edge does not exist (it is abnormal and we've | |
34 | inserted a fake to compensate). */ | |
35 | unsigned int ignore:1; | |
36 | }; | |
37 | ||
38 | #define EDGE_INFO(e) ((struct edge_info *) (e)->aux) | |
39 | ||
40 | /* Smoothes the initial assigned basic block and edge counts using | |
41 | a minimum cost flow algorithm. */ | |
42 | extern void mcf_smooth_cfg (void); | |
43 | ||
9771b263 | 44 | extern gcov_type sum_edge_counts (vec<edge, va_gc> *edges); |
3aa71f9d | 45 | |
903d1e67 XDL |
46 | extern void init_node_map (void); |
47 | extern void del_node_map (void); | |
48 | ||
f57ddb5b | 49 | extern void get_working_sets (void); |
2730ada7 | 50 | |
0208f7da JH |
51 | /* In predict.c. */ |
52 | extern gcov_type get_hot_bb_threshold (void); | |
53 | extern void set_hot_bb_threshold (gcov_type); | |
54 | ||
3aa71f9d | 55 | #endif /* PROFILE_H */ |