3 * File name: ir/stat/firmstat.h
4 * Purpose: Statistics for Firm.
8 * Copyright: (c) 2004 Universität Karlsruhe
9 * Licence: This file protected by GPL - GNU GENERAL PUBLIC LICENSE.
22 * Statistic options, can be or'ed.
24 enum firmstat_options_t {
25 FIRMSTAT_ENABLED = 0x00000001, /**< enable statistics */
26 FIRMSTAT_PATTERN_ENABLED = 0x00000002, /**< enable pattern calculation */
27 FIRMSTAT_COUNT_STRONG_OP = 0x00000004, /**< if set, count Mul/Div/Mod/DivMod by constant */
28 FIRMSTAT_COUNT_DAG = 0x00000008, /**< if set, count DAG statistics */
29 FIRMSTAT_COUNT_DELETED = 0x00000010, /**< if set, count deleted graphs */
30 FIRMSTAT_CSV_OUTPUT = 0x10000000 /**< CSV output of some mini-statistic */
34 * Finish the statistics.
35 * Never called from libFirm should be called from user.
37 * @param name basename of the statistic output file
39 void stat_finish(const char *name);
41 #ifdef FIRM_STATISTICS
44 * initialize the statistics module.
46 * @param enable_options a bitmask containing the statistic options
48 void init_stat(unsigned enable_options);
52 #define init_stat(enable_options)
54 #endif /* FIRM_STATISTICS */
56 #endif /* _FIRMSTAT_H_ */