backend: ProjT/Start is an anchor and explicitely transformed
[libfirm] / ir / be / sparc / bearch_sparc.c
index 5a819db..cdb5877 100644 (file)
@@ -202,7 +202,7 @@ static void transform_Spill(ir_node *node)
        dbg_info  *dbgi   = get_irn_dbg_info(node);
        ir_node   *ptr    = get_irn_n(node, n_be_Spill_frame);
        ir_graph  *irg    = get_irn_irg(node);
-       ir_node   *mem    = new_r_NoMem(irg);
+       ir_node   *mem    = get_irg_no_mem(irg);
        ir_node   *val    = get_irn_n(node, n_be_Spill_val);
        ir_mode   *mode   = get_irn_mode(val);
        ir_entity *entity = be_get_frame_entity(node);
@@ -292,6 +292,8 @@ static void sparc_after_ra(ir_graph *irg)
        be_free_frame_entity_coalescer(fec_env);
 
        irg_block_walk_graph(irg, NULL, sparc_after_ra_walker, NULL);
+
+       sparc_introduce_prolog_epilog(irg);
 }
 
 static void sparc_init_graph(ir_graph *irg)
@@ -310,7 +312,6 @@ static sparc_isa_t sparc_isa_template = {
                &sparc_registers[REG_SP],           /* stack pointer register */
                &sparc_registers[REG_FRAME_POINTER],/* base pointer register */
                &sparc_reg_classes[CLASS_sparc_gp], /* link pointer register class */
-               -1,                                 /* stack direction */
                3,                                  /* power of two stack alignment
                                                       for calls */
                NULL,                               /* main environment */
@@ -483,7 +484,7 @@ static void sparc_handle_intrinsics(void)
 static arch_env_t *sparc_init(FILE *outfile)
 {
        sparc_isa_t *isa = XMALLOC(sparc_isa_t);
-       memcpy(isa, &sparc_isa_template, sizeof(*isa));
+       *isa = sparc_isa_template;
        isa->constants = pmap_create();
 
        be_emit_init(outfile);