diff options
author | Alex AUVOLAT <alex.auvolat@ens.fr> | 2014-01-14 17:34:02 +0100 |
---|---|---|
committer | Alex AUVOLAT <alex.auvolat@ens.fr> | 2014-01-14 17:34:02 +0100 |
commit | 036b6ba1caae40b439670c031a162a6fde7461ec (patch) | |
tree | 3826129be2a8fd3d0d21a5483cdce157b9d5a909 /sched | |
parent | 0eaeee0945dfd931ba83ffe0280f422dc09dd99b (diff) | |
download | SystDigit-Projet-036b6ba1caae40b439670c031a162a6fde7461ec.tar.gz SystDigit-Projet-036b6ba1caae40b439670c031a162a6fde7461ec.zip |
Changes...
Diffstat (limited to 'sched')
-rw-r--r-- | sched/simplify.ml | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sched/simplify.ml b/sched/simplify.ml index a2c7770..582d5d0 100644 --- a/sched/simplify.ml +++ b/sched/simplify.ml @@ -147,6 +147,10 @@ let arith_simplify p = | Emux(_, a, b) when a = b -> Earg(a) | Emux(Aconst[|false|], a, b) -> Earg(a) | Emux(Aconst[|true|], a, b) -> Earg(b) + | Emux(c, Aconst[|false|], Avar(b)) when Env.find b p.p_vars = 1 -> + Ebinop(And, c, Avar(b)) + | Emux(c, Avar(b), Aconst[|true|]) when Env.find b p.p_vars = 1 -> + Ebinop(Or, c, Avar(b)) | Eslice(i, j, k) when i = j -> Eselect(i, k) |