entity *ent = be_get_frame_entity(n);
offset = get_entity_offset_bytes(ent);
} else if (irn_op == op_be_Reload || irn_op == op_be_Spill) {
- entity * ent = be_get_spill_entity(n);
+ entity *ent = be_get_frame_entity(n);
offset = get_entity_offset_bytes(ent);
} else if (irn_op == op_be_IncSP) {
- int offs = be_get_IncSP_offset(n);
- be_stack_dir_t dir = be_get_IncSP_direction(n);
- offset = (dir == be_stack_dir_expand) ? -offs : offs;
+ offset = - be_get_IncSP_offset(n);
} else {
return "node_offset_to_str will fuer diesen Knotentyp noch implementiert werden";
}
static char *get_cfop_target(const ir_node *irn, char *buf) {
ir_node *bl = get_irn_link(irn);
- snprintf(buf, SNPRINTF_BUF_LEN, "BLOCK_%d", get_irn_node_nr(bl));
+ snprintf(buf, SNPRINTF_BUF_LEN, "BLOCK_%ld", get_irn_node_nr(bl));
return buf;
}
if (proj_num == pn_Cmp_False) {
/* always false: should not happen */
- fprintf(out, "\tb BLOCK_%d\t\t\t/* false case */\n", get_irn_node_nr(false_block));
+ fprintf(out, "\tb BLOCK_%ld\t\t\t/* false case */\n", get_irn_node_nr(false_block));
} else if (proj_num == pn_Cmp_True) {
/* always true: should not happen */
- fprintf(out, "\tb BLOCK_%d\t\t\t/* true case */\n", get_irn_node_nr(true_block));
+ fprintf(out, "\tb BLOCK_%ld\t\t\t/* true case */\n", get_irn_node_nr(true_block));
} else {
ir_node *block = get_nodes_block(irn);
/** Emit an IncSP node */
static void emit_be_IncSP(const ir_node *irn, arm_emit_env_t *emit_env) {
FILE *F = emit_env->out;
- unsigned offs = be_get_IncSP_offset(irn);
- if (offs) {
+ int offs = be_get_IncSP_offset(irn);
+
+ if (offs != 0) {
char cmd_buf[SNPRINTF_BUF_LEN], cmnt_buf[SNPRINTF_BUF_LEN];
lc_esnprintf(arm_get_arg_env(), cmd_buf, SNPRINTF_BUF_LEN, "add %1D, %1S, #%O", irn, irn, irn );
lc_esnprintf(arm_get_arg_env(), cmnt_buf, SNPRINTF_BUF_LEN, "/* IncSP(%O) */", irn);
static void emit_be_Perm(const ir_node* irn, arm_emit_env_t *emit_env) {
FILE *F = emit_env->out;
- ir_mode *mode = get_irn_mode(irn);
const lc_arg_env_t *arm_env = arm_get_arg_env();
char cmd_buf[SNPRINTF_BUF_LEN], cmnt_buf[SNPRINTF_BUF_LEN];
void arm_gen_block(ir_node *block, void *env) {
ir_node *irn;
- fprintf(((arm_emit_env_t *)env)->out, "BLOCK_%d:\n", get_irn_node_nr(block));
+ fprintf(((arm_emit_env_t *)env)->out, "BLOCK_%ld:\n", get_irn_node_nr(block));
sched_foreach(block, irn) {
arm_emit_node(irn, env);
}
arm_register_emitters();
/* create the block schedule. For now, we don't need it earlier. */
- blk_sched = sched_create_block_schedule(cg->irg);
+ blk_sched = sched_create_block_schedule(cg->irg, cg->birg->exec_freq);
arm_emit_start(F, irg);
irg_block_walk_graph(irg, arm_gen_labels, NULL, &emit_env);