src/lima/pp_lir/regalloc.c
//Gets the interference matrix, where each channel of each variable has an entry.
//Used for move elimination.
Gets the interference matrix, where each channel of each variable has an entry.
Used for move elimination.
Gets the interference matrix where each channel of each variable has an entry . Used for move elimination .
static bitset_t calc_detailed_int_matrix(lima_pp_lir_prog_t* prog)
{
	unsigned i;
	bitset_t ret = bitset_create(16 * (prog->reg_alloc + 1) * (prog->reg_alloc + 1));
	for (i = 0; i < prog->num_regs; i++)
	{
		lima_pp_lir_reg_t* reg = prog->regs[i];
		lima_pp_lir_instr_t* def;
		ptrset_iter_t iter = ptrset_iter_create(reg->defs);
		ptrset_iter_for_each(iter, def)
		{
			add_edge_instr(def, ret, prog->reg_alloc);
		}
	}
	return ret;
}
static bitset_t calc_detailed_int_matrix ( lima_pp_lir_prog_t * prog ) { unsigned i ; bitset_t ret = bitset_create ( 16 * ( prog -> reg_alloc + 1 ) * ( prog -> reg_alloc + 1 ) ) ; for ( i = 0 ; i < prog -> num_regs ; i ++ ) { lima_pp_lir_reg_t * reg = prog -> regs [ i ] ; lima_pp_lir_instr_t * def ; ptrset_iter_t iter = ptrset_iter_create ( reg -> defs ) ; ptrset_iter_for_each ( iter , def ) { add_edge_instr ( def , ret , prog -> reg_alloc ) ; } } return ret ; }
Gets the interference matrix, where each channel of each variable has an entry.
Gets the interference matrix where each channel of each variable has an entry .