]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Add a spec rule for NS after LOGICB. Fixes #266990.
authorJulian Seward <jseward@acm.org>
Sun, 27 Mar 2011 22:16:08 +0000 (22:16 +0000)
committerJulian Seward <jseward@acm.org>
Sun, 27 Mar 2011 22:16:08 +0000 (22:16 +0000)
git-svn-id: svn://svn.valgrind.org/vex/trunk@2118

VEX/priv/guest_amd64_helpers.c

index f626f0a8b1bccb6c2922beeb4d3f7103874de3fc..cea850f42373256fa4d6b1c57efb9dcc085d9044 100644 (file)
@@ -1179,6 +1179,14 @@ IRExpr* guest_amd64_spechelper ( HChar* function_name,
                       binop(Iop_Shr64,cc_dep1,mkU8(7)),
                       mkU64(1));
       }
+      if (isU64(cc_op, AMD64G_CC_OP_LOGICB) && isU64(cond, AMD64CondNS)) {
+         /* byte and/or/xor, then NS --> (UInt)!result[7] */
+         return binop(Iop_Xor64,
+                      binop(Iop_And64,
+                            binop(Iop_Shr64,cc_dep1,mkU8(7)),
+                            mkU64(1)),
+                      mkU64(1));
+      }
 
       /*---------------- INCB ----------------*/