req = arch_get_register_req(env->co->aenv, irn, BE_OUT_POS(0));
- if(arch_register_req_is(req, limited)) {
- unsigned n_regs = env->co->cls->n_regs;
+ if (arch_register_req_is(req, limited)) {
+ unsigned n_regs = env->co->cls->n_regs;
unsigned n_constr = 0;
- int i;
+ unsigned i;
n_constr = rbitset_popcnt(req->limited, n_regs);
- for(i = 0; i < n_regs; ++i) {
- if(rbitset_is_set(req->limited, i)) {
- col_costs[i].costs = add_saturated(col_costs[i].costs, costs / n_constr);
+ for (i = 0; i < n_regs; ++i) {
+ if (rbitset_is_set(req->limited, i)) {
+ col_costs[i].costs = add_saturated(col_costs[i].costs, costs / n_constr);
}
}
}
char prof_filename[256];
static const char suffix[] = ".prof";
be_irg_t *birgs;
- unsigned num_birgs;
+ int num_birgs;
ir_graph **irg_list, **backend_irg_list;
lc_timer_t *t_abi = NULL;
be_profile_instrument(const char *filename, unsigned flags)
{
int n, i;
- unsigned int n_blocks = 0;
+ int n_blocks = 0;
ir_entity *bblock_id;
ir_entity *bblock_counts;
ir_entity *ent_filename;
*/
if (add_edge) {
- int vv_height = get_irn_height(rss->h, vv_irn);
- int mu1, mu2, critical_path_cost;
+ unsigned vv_height = get_irn_height(rss->h, vv_irn);
+ unsigned critical_path_cost;
+ unsigned mu1, mu2;
/*
mu1 = | descendants(v) cut sat_vals |
static void perform_value_serialization_heuristic(rss_t *rss) {
bitset_t *arch_nonign_bs = bitset_alloca(arch_register_class_n_regs(rss->cls));
bitset_t *abi_ign_bs = bitset_alloca(arch_register_class_n_regs(rss->cls));
- int available_regs, iteration;
+ unsigned available_regs, iteration;
dvg_t dvg;
ir_nodeset_t *sat_vals;
pset *ser_set = new_pset(cmp_rss_edges, 20);
}
pressure = be_get_loop_pressure(env->loop_ana, env->cls, loop);
- assert(ARR_LEN(delayed) <= pressure);
+ assert(ARR_LEN(delayed) <= (signed)pressure);
free_slots = env->n_regs - ARR_LEN(starters);
free_pressure_slots = env->n_regs - (pressure - ARR_LEN(delayed));
free_slots = MIN(free_slots, free_pressure_slots);
const be_use_t *use;
const ir_node *succ_block = get_edge_src_irn(edge);
ir_loop *succ_loop;
- int use_dist;
+ unsigned use_dist;
if(succ_block == startblock)
continue;
succ_loop = get_irn_loop(succ_block);
if(get_loop_depth(succ_loop) < loopdepth) {
- int factor = (loopdepth - get_loop_depth(succ_loop)) * 5000;
+ unsigned factor = (loopdepth - get_loop_depth(succ_loop)) * 5000;
DBG((env->dbg, LEVEL_5, "Increase usestep because of loop out edge %d -> %d (%u)\n", factor));
// TODO we should use the number of nodes in the loop or so...
use_dist += factor;