From 4e67510841f90c9591d43b7f690773b07e304502 Mon Sep 17 00:00:00 2001 From: Florian Krohm Date: Wed, 16 Jul 2014 20:17:49 +0000 Subject: [PATCH] Fix algebraic simplification for Iop_AndV256. git-svn-id: svn://svn.valgrind.org/vex/trunk@2902 --- VEX/priv/ir_opt.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/VEX/priv/ir_opt.c b/VEX/priv/ir_opt.c index 03a06e3054..ded301882d 100644 --- a/VEX/priv/ir_opt.c +++ b/VEX/priv/ir_opt.c @@ -1253,6 +1253,7 @@ static IRExpr* mkZeroOfPrimopResultType ( IROp op ) case Iop_Xor64: return IRExpr_Const(IRConst_U64(0)); case Iop_XorV128: case Iop_AndV128: return IRExpr_Const(IRConst_V128(0)); + case Iop_AndV256: return IRExpr_Const(IRConst_V256(0)); default: vpanic("mkZeroOfPrimopResultType: bad primop"); } } @@ -2195,9 +2196,9 @@ static IRExpr* fold_Expr ( IRExpr** env, IRExpr* e ) } /* Deal with either arg zero. Could handle other And cases here too. */ - if (e->Iex.Binop.op == Iop_And64 - && (isZeroU64(e->Iex.Binop.arg1) - || isZeroU64(e->Iex.Binop.arg2))) { + if (e->Iex.Binop.op == Iop_AndV256 + && (isZeroV256(e->Iex.Binop.arg1) + || isZeroV256(e->Iex.Binop.arg2))) { e2 = mkZeroOfPrimopResultType(e->Iex.Binop.op); break; } else if (e->Iex.Binop.op == Iop_AndV128 -- 2.47.2