]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Yet another %eflags folding rule - this one for performance reasons.
authorJulian Seward <jseward@acm.org>
Thu, 25 May 2006 01:04:05 +0000 (01:04 +0000)
committerJulian Seward <jseward@acm.org>
Thu, 25 May 2006 01:04:05 +0000 (01:04 +0000)
git-svn-id: svn://svn.valgrind.org/vex/trunk@1624

VEX/priv/guest-x86/ghelpers.c

index 1929f02949a376c85e185da6a8a39d4c5ccacd47..2e6ff1dbf8ed85cc3a307de5d56cb3df8c8a200c 100644 (file)
@@ -935,6 +935,11 @@ IRExpr* guest_x86_spechelper ( HChar* function_name,
          return unop(Iop_1Uto32,binop(Iop_CmpEQ32, cc_dep1, mkU32(0)));
       }
 
+      if (isU32(cc_op, X86G_CC_OP_LOGICL) && isU32(cond, X86CondNZ)) {
+         /* long and/or/xor, then NZ --> test dst!=0 */
+         return unop(Iop_1Uto32,binop(Iop_CmpNE32, cc_dep1, mkU32(0)));
+      }
+
       if (isU32(cc_op, X86G_CC_OP_LOGICL) && isU32(cond, X86CondLE)) {
          /* long and/or/xor, then LE
             This is pretty subtle.  LOGIC sets SF and ZF according to the