summaryrefslogtreecommitdiffhomepage
path: root/ir/be/bearch.h
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2015-06-30 08:07:07 +0200
committerMatthias Braun <matze@braunis.de>2015-07-01 07:40:03 +0200
commitc15ec9596306be5ea62c087d37024f0cac05d490 (patch)
tree7f1194ce671d1c4d68c405ab86ba2382080bac58 /ir/be/bearch.h
parent58b0168a2361d25b641eb0d5b8382ee75173b562 (diff)
bearch: rework should_be_same constraint
- Rename other_same field to should_be_same. - Remove arch_register_req_type_other_same, it's enough to see if the should_be_same field is not zero.
Diffstat (limited to 'ir/be/bearch.h')
-rw-r--r--ir/be/bearch.h14
1 files changed, 6 insertions, 8 deletions
diff --git a/ir/be/bearch.h b/ir/be/bearch.h
index c245377..dff39da 100644
--- a/ir/be/bearch.h
+++ b/ir/be/bearch.h
@@ -26,14 +26,12 @@
typedef enum arch_register_req_type_t {
/** No special type, but may still have a limited array set. */
arch_register_req_type_none = 0,
- /** The register should be equal to another one at the node. */
- arch_register_req_type_should_be_same = 1U << 0,
/** The register must be unequal from some other at the node. */
- arch_register_req_type_must_be_different = 1U << 1,
+ arch_register_req_type_must_be_different = 1U << 0,
/** The registernumber should be aligned (in case of multiregister values)*/
- arch_register_req_type_aligned = 1U << 2,
+ arch_register_req_type_aligned = 1U << 1,
/** ignore while allocating registers */
- arch_register_req_type_ignore = 1U << 3,
+ arch_register_req_type_ignore = 1U << 2,
} arch_register_req_type_t;
ENUM_BITSET(arch_register_req_type_t)
@@ -228,8 +226,8 @@ struct arch_register_req_t {
* first register). NULL if all registers are allowed. */
const unsigned *limited;
arch_register_req_type_t type; /**< The type of the constraint. */
- /** Bitmask of ins which should use the same register (should_be_same). */
- unsigned other_same;
+ /** Bitmask of ins which should use the same register. */
+ unsigned should_be_same;
/** Bitmask of ins which shall use a different register (must_be_different) */
unsigned other_different;
/** Specifies how many sequential registers are required */
@@ -244,7 +242,7 @@ static inline bool reg_reqs_equal(const arch_register_req_t *req1,
if (req1->type != req2->type ||
req1->cls != req2->cls ||
- req1->other_same != req2->other_same ||
+ req1->should_be_same != req2->should_be_same ||
req1->other_different != req2->other_different ||
(req1->limited != NULL) != (req2->limited != NULL))
return false;