aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/validation/optim
diff options
authorLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2020-11-07 01:09:07 +0100
committerLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2020-11-07 12:27:49 +0100
commit84bf7462ebc80b350b0d2b35156bae04b8d5feb1 (patch)
tree03156e3b9efafed7777e0c4a82d4259206de4223 /validation/optim
parent93bb38fdbfb16f8382954db1e02a6ff1731bd60f (diff)
downloadsparse-dev-84bf7462ebc80b350b0d2b35156bae04b8d5feb1.tar.gz
select: simplify SEL(SEL(x, C1, C2), y, z) --> y (with C1, C2 != 0)
If the condition of a select is also a select, with constant but non-zero operands, then the result of this inner select is always true and the outer select can be replaced by its second operand. Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Diffstat (limited to 'validation/optim')
-rw-r--r--validation/optim/select-select-true-true.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/validation/optim/select-select-true-true.c b/validation/optim/select-select-true-true.c
index e6fa2c89..c0c26fdd 100644
--- a/validation/optim/select-select-true-true.c
+++ b/validation/optim/select-select-true-true.c
@@ -3,7 +3,6 @@ int foo(int p, int a, int b) { return ((p ? 42 : 43) ? a : b) == a ; }
/*
* check-name: select-select-true-true
* check-command: test-linearize -Wno-decl $file
- * check-known-to-fail
*
* check-output-ignore
* check-output-returns: 1