summaryrefslogtreecommitdiff
path: root/gcc/function.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/function.h')
-rw-r--r--gcc/function.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/function.h b/gcc/function.h
index bc789c8181a..912f8513c53 100644
--- a/gcc/function.h
+++ b/gcc/function.h
@@ -481,6 +481,19 @@ struct function
/* Nonzero if code to initialize arg_pointer_save_area has been emited. */
unsigned int arg_pointer_save_area_init : 1;
+
+ /* How commonly executed the function is. Initialized during branch
+ probabilities pass. */
+ enum function_frequency {
+ /* This function most likely won't be executed at all.
+ (set only when profile feedback is available). */
+ FUNCTION_FREQUENCY_UNLIKELY_EXECUTED,
+ /* The default value. */
+ FUNCTION_FREQUENCY_NORMAL,
+ /* Optimize this function hard
+ (set only when profile feedback is available). */
+ FUNCTION_FREQUENCY_HOT
+ } function_frequency;
};
/* The function currently being compiled. */