]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Handle Iop_Max32U, so as to make origin tracking in Memcheck work.
authorJulian Seward <jseward@acm.org>
Tue, 8 Apr 2014 15:24:15 +0000 (15:24 +0000)
committerJulian Seward <jseward@acm.org>
Tue, 8 Apr 2014 15:24:15 +0000 (15:24 +0000)
git-svn-id: svn://svn.valgrind.org/vex/trunk@2848

VEX/priv/host_arm64_isel.c

index 396f5b104b1309d38ea63be7c464ae1094ab56b3..adf117129b1f9463955b4fe4d7d84a2290fd703a 100644 (file)
@@ -1760,16 +1760,14 @@ static HReg iselIntExpr_R_wrk ( ISelEnv* env, IRExpr* e )
 
       /* Handle misc other ops. */
 
-//ZZ       if (e->Iex.Binop.op == Iop_Max32U) {
-//ZZ          HReg argL = iselIntExpr_R(env, e->Iex.Binop.arg1);
-//ZZ          HReg argR = iselIntExpr_R(env, e->Iex.Binop.arg2);
-//ZZ          HReg dst  = newVRegI(env);
-//ZZ          addInstr(env, ARMInstr_CmpOrTst(True/*isCmp*/, argL,
-//ZZ                                          ARMRI84_R(argR)));
-//ZZ          addInstr(env, mk_iMOVds_RR(dst, argL));
-//ZZ          addInstr(env, ARMInstr_CMov(ARMcc_LO, dst, ARMRI84_R(argR)));
-//ZZ          return dst;
-//ZZ       }
+      if (e->Iex.Binop.op == Iop_Max32U) {
+         HReg argL = iselIntExpr_R(env, e->Iex.Binop.arg1);
+         HReg argR = iselIntExpr_R(env, e->Iex.Binop.arg2);
+         HReg dst  = newVRegI(env);
+         addInstr(env, ARM64Instr_Cmp(argL, ARM64RIA_R(argR), False/*!is64*/));
+         addInstr(env, ARM64Instr_CSel(dst, argL, argR, ARM64cc_CS));
+         return dst;
+      }
 
       if (e->Iex.Binop.op == Iop_32HLto64) {
          HReg hi32s = iselIntExpr_R(env, e->Iex.Binop.arg1);