amd64: Added Load and FrameAddr transformation. And fixed some corruption bugs w...
[libfirm] / ir / be / beabi.c
index 9568bd7..8be3fb2 100644 (file)
@@ -26,7 +26,6 @@
 #include "config.h"
 
 #include "obst.h"
-#include "offset.h"
 
 #include "irgopt.h"
 
@@ -1657,9 +1656,10 @@ static void fix_address_of_parameter_access(be_abi_irg_t *env, ent_pos_pair *val
                for (entry = new_list; entry != NULL; entry = entry->next) {
                        ir_entity *ent = entry->ent;
 
-                       /* If the entity is still on the argument type, move it to the frame type.
-                          This happens if the value_param type was build due to compound
-                          params. */
+                       /* If the entity is still on the argument type, move it to the
+                        * frame type.
+                        * This happens if the value_param type was build due to compound
+                        * params. */
                        if (get_entity_owner(ent) != frame_tp) {
                                ir_type  *tp   = get_entity_type(ent);
                                unsigned align = get_type_alignment_bytes(tp);
@@ -1667,7 +1667,6 @@ static void fix_address_of_parameter_access(be_abi_irg_t *env, ent_pos_pair *val
                                offset += align - 1;
                                offset &= ~(align - 1);
                                set_entity_owner(ent, frame_tp);
-                               add_class_member(frame_tp, ent);
                                /* must be automatic to set a fixed layout */
                                set_entity_offset(ent, offset);
                                offset += get_type_size_bytes(tp);
@@ -2413,6 +2412,8 @@ static void collect_stack_nodes_walker(ir_node *node, void *data)
 
        if (arch_irn_get_n_outs(insn) == 0)
                return;
+       if (get_irn_mode(node) == mode_T)
+               return;
 
        req = arch_get_register_req_out(node);
        if (! (req->type & arch_register_req_type_produces_sp))