Commit 74c827f2 authored by Matthias Braun's avatar Matthias Braun
Browse files

make sure the width field is always initialized to 1 for normal constraints

[r27875]
parent efdb09dd
......@@ -483,6 +483,7 @@ ir_node *be_new_Copy(const arch_register_class_t *cls, ir_node *bl, ir_node *op)
req->cls = cls;
req->type = arch_register_req_type_should_be_same;
req->other_same = 1U << 0;
req->width = 1;
be_set_constr_out(res, 0, req);
return res;
......@@ -920,6 +921,7 @@ const arch_register_req_t *be_create_reg_req(struct obstack *obst,
req->type = arch_register_req_type_limited | additional_types;
req->cls = cls;
req->limited = limited_bitset;
req->width = 1;
return req;
}
......
......@@ -836,6 +836,7 @@ const arch_register_req_t *make_register_req(const constraint_t *constraint,
*req = *other_constr;
req->type |= arch_register_req_type_should_be_same;
req->other_same = 1U << pos;
req->width = 1;
/* switch constraints. This is because in firm we have same_as
* constraints on the output constraints while in the gcc asm syntax
......@@ -865,7 +866,8 @@ const arch_register_req_t *make_register_req(const constraint_t *constraint,
memset(req, 0, sizeof(req[0]));
req->type = arch_register_req_type_normal;
}
req->cls = constraint->cls;
req->cls = constraint->cls;
req->width = 1;
return req;
}
......@@ -891,6 +893,7 @@ const arch_register_req_t *parse_clobber(const char *clobber)
req->type = arch_register_req_type_limited;
req->cls = arch_register_get_class(reg);
req->limited = limited;
req->width = 1;
return req;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment