attr->data.am_scale = scale;
}
+void ia32_copy_am_attrs(ir_node *to, const ir_node *from)
+{
+ set_ia32_ls_mode(to, get_ia32_ls_mode(from));
+ set_ia32_am_scale(to, get_ia32_am_scale(from));
+ set_ia32_am_sc(to, get_ia32_am_sc(from));
+ if(is_ia32_am_sc_sign(from))
+ set_ia32_am_sc_sign(to);
+ add_ia32_am_offs_int(to, get_ia32_am_offs_int(from));
+ set_ia32_frame_ent(to, get_ia32_frame_ent(from));
+ if (is_ia32_use_frame(from))
+ set_ia32_use_frame(to);
+}
+
/**
* Sets the uses_frame flag.
*/
const be_execution_unit_t ***execution_units,
int n_res, unsigned latency)
{
- ir_graph *irg = get_irn_irg(node);
- struct obstack *obst = get_irg_obstack(irg);
- ia32_attr_t *attr = get_ia32_attr(node);
- arch_register_t**slots;
+ ir_graph *irg = get_irn_irg(node);
+ struct obstack *obst = get_irg_obstack(irg);
+ ia32_attr_t *attr = get_ia32_attr(node);
set_ia32_flags(node, flags);
set_ia32_in_req_all(node, in_reqs);
attr->out_flags = NEW_ARR_D(int, obst, n_res);
memset(attr->out_flags, 0, n_res * sizeof(attr->out_flags[0]));
- attr->slots = slots = NEW_ARR_D(arch_register_t*, obst, n_res);
- memset(slots, 0, n_res * sizeof(slots[0]));
+ attr->slots = NEW_ARR_D(const arch_register_t*, obst, n_res);
+ /* void* cast to suppress an incorrect warning on MSVC */
+ memset((void*)attr->slots, 0, n_res * sizeof(attr->slots[0]));
}
void