Clarify interpretation of limited for wide values
authorMatthias Braun <matze@braunis.de>
Tue, 10 Jan 2012 12:59:20 +0000 (13:59 +0100)
committerMatthias Braun <matthias.braun@kit.edu>
Thu, 1 Mar 2012 15:02:00 +0000 (16:02 +0100)
ir/be/bearch.h
ir/be/becopyilp2.c

index e14d3c5..f0ed3bd 100644 (file)
@@ -307,14 +307,16 @@ struct arch_register_req_t {
        arch_register_req_type_t     type; /**< The type of the constraint. */
        const arch_register_class_t *cls;  /**< The register class this constraint
                                                belongs to. */
-       const unsigned *limited;            /**< allowed register bitset */
-       unsigned other_same;                /**< Bitmask of ins which should use the
-                                                same register (should_be_same). */
-       unsigned other_different;           /**< Bitmask of ins which shall use a
-                                                different register
-                                                (must_be_different) */
-       unsigned char width;                /**< specifies how many sequential
-                                                registers are required */
+       const unsigned *limited;           /**< allowed register bitset
+                                               (in case of wide-values this is
+                                                only about the first register) */
+       unsigned other_same;               /**< Bitmask of ins which should use the
+                                               same register (should_be_same). */
+       unsigned other_different;          /**< Bitmask of ins which shall use a
+                                               different register
+                                               (must_be_different) */
+       unsigned char width;               /**< specifies how many sequential
+                                               registers are required */
 };
 
 static inline bool reg_reqs_equal(const arch_register_req_t *req1,
index 8527319..49f89b4 100644 (file)
@@ -148,15 +148,6 @@ static void build_coloring_cstr(ilp_env_t *ienv)
                                && (!has_alignment_cstr || ((col % req->width) == 0)))
                                continue;
 
-                       // If it is possible to have only a part of a large variable that
-                       // cannot be used, we should invalidate the whole piece.
-                       // Since we do not think this can happen, we did implemented the
-                       // support for that.
-                       assert((!has_alignment_cstr
-                                       || rbitset_is_set(colors, col)
-                                       || !rbitset_is_set(colors, col - (col % req->width)))
-                                  && "Register constraints that invalidate just a part of "
-                                  "a large variable is not yet supported");
                        make_color_var_name(buf, sizeof(buf), irn, col);
                        cst_idx = lpp_add_cst(ienv->lp, NULL, lpp_equal, 0.0);
                        var_idx = lpp_add_var(ienv->lp, buf, lpp_binary, 0.0);