summaryrefslogtreecommitdiffhomepage
path: root/ir/be/belive.c
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2014-10-16 15:51:03 +0200
committerMatthias Braun <matze@braunis.de>2014-10-18 20:42:47 +0200
commit91aae509bd4ca6eb992f30690196e079e19c31ee (patch)
tree68c7e9a89e05e119dd7ee6602a087ecf0da51596 /ir/be/belive.c
parentd43b03bdc88f632bdac7552879571cd12abf6572 (diff)
assure that liveness_{update,remove,introduce} is only called with valid live sets
Diffstat (limited to 'ir/be/belive.c')
-rw-r--r--ir/be/belive.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ir/be/belive.c b/ir/be/belive.c
index b4bf315..1853546 100644
--- a/ir/be/belive.c
+++ b/ir/be/belive.c
@@ -340,8 +340,7 @@ void be_liveness_free(be_lv_t *lv)
void be_liveness_remove(be_lv_t *lv, const ir_node *irn)
{
- if (!lv->sets_valid)
- return;
+ assert(lv->sets_valid);
/* Removes a single irn from the liveness information.
* Since an irn can only be live at blocks dominated by the block of its
@@ -352,8 +351,9 @@ void be_liveness_remove(be_lv_t *lv, const ir_node *irn)
void be_liveness_introduce(be_lv_t *lv, ir_node *irn)
{
+ assert(lv->sets_valid);
/* Don't compute liveness information for non-data nodes. */
- if (lv->sets_valid && is_liveness_node(irn)) {
+ if (is_liveness_node(irn)) {
re.lv = lv;
liveness_for_node(irn);
}