fixed be_sched_ready statistics
authorChristian Würdig <chriswue@ipd.info.uni-karlsruhe.de>
Mon, 10 Apr 2006 09:24:16 +0000 (09:24 +0000)
committerChristian Würdig <chriswue@ipd.info.uni-karlsruhe.de>
Mon, 10 Apr 2006 09:24:16 +0000 (09:24 +0000)
ir/be/bestat.c

index 030d8cf..ab415d6 100644 (file)
@@ -10,6 +10,9 @@
 #include "belive_t.h"
 #include "besched.h"
 
+#undef MIN
+#define MIN(a, b) (a < b ? a : b)
+
 /**
  * Collect reg pressure statistics per block and per class.
  */
@@ -49,5 +52,5 @@ void be_do_stat_reg_pressure(be_irg_t *birg) {
  * Notify statistic module about amount of ready nodes.
  */
 void be_do_stat_sched_ready(ir_node *block, nodeset *ready_set) {
-       hook_be_block_sched_ready(block, get_irn_irg(block), nodeset_count(ready_set));
+       hook_be_block_sched_ready(block, get_irn_irg(block), MIN(nodeset_count(ready_set), 5));
 }