From 66a85ef5ee56713b80b444e55963354ff923f0f0 Mon Sep 17 00:00:00 2001 From: Michael Beck Date: Tue, 3 May 2011 11:52:11 +0200 Subject: [PATCH] Fixed combo by fixing an old artefact from the older libFirm Cmp nodes. In older libFirm version, Cmp computes top, true or bottom. Now Cmp computes true or false, so the monotony fix must be upgraded. This fixes opt/combo_paper.c --- ir/opt/combo.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ir/opt/combo.c b/ir/opt/combo.c index d1e3e0e77..b930563ad 100644 --- a/ir/opt/combo.c +++ b/ir/opt/combo.c @@ -2258,11 +2258,11 @@ static void compute_Cmp(node_t *node) } else if (r->part == l->part && !mode_is_float(get_irn_mode(l->node))) { tv = relation & ir_relation_equal ? tarval_b_true : tarval_b_false; - /* if the node was ONCE evaluated by all constants, but now + /* if the node was ONCE evaluated to a constant, but now this breaks AND we get from the argument partitions a different - result, switch to bottom. + result, ensure monotony by fall to bottom. This happens because initially all nodes are in the same partition ... */ - if (node->type.tv != tv) + if (node->type.tv != tv && is_constant_type(node->type)) tv = tarval_bottom; node->type.tv = tv; } else { -- 2.20.1