Commit 21be21bc authored by Michael Beck's avatar Michael Beck
Browse files

bestat is only compiled if FIRMSTAT is defined

parent cd4ab968
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#ifdef FIRM_STATISTICS
#include "irnode_t.h"
#include "irprintf.h"
#include "irgwalk.h"
......@@ -54,3 +60,10 @@ void be_do_stat_reg_pressure(be_irg_t *birg) {
void be_do_stat_sched_ready(ir_node *block, nodeset *ready_set) {
hook_be_block_sched_ready(block, get_irn_irg(block), MIN(nodeset_count(ready_set), 5));
}
#else
void (be_do_stat_reg_pressure)(be_irg_t *birg) {}
void (be_do_stat_sched_ready)(ir_node *block, nodeset *ready_set) {}
#endif /* FIRM_STATISTICS */
#ifndef _BESTAT_H_
#define _BESTAT_H_
#include "firm_config.h"
#include "be_t.h"
#include "benodesets.h"
#ifdef FIRM_STATISTICS
/**
* Collects statistics information about register pressure.
* @param birg The be irg object containing the irg
......@@ -11,10 +14,17 @@
void be_do_stat_reg_pressure(be_irg_t *birg);
/**
* Collect statistics about amount of redy nodes per block
* Collect statistics about amount of ready nodes per block
* @param block The block
* @param ready_set A set of ready nodes
*/
void be_do_stat_sched_ready(ir_node *block, nodeset *ready_set);
#else
#define be_do_stat_reg_pressure(birg)
#define be_do_stat_sched_ready(block, ready_set)
#endif /* FIRM_STATISTICS */
#endif /* _BESTAT_H_ */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment