Skip to content

Commit

Permalink
AMD64: Add a spechelper for ADDL and CondZ. (angr#47)
Browse files Browse the repository at this point in the history
  • Loading branch information
ltfish authored Dec 23, 2021
1 parent 5b3cab1 commit 9bcfa42
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions priv/guest_amd64_helpers.c
Original file line number Diff line number Diff line change
Expand Up @@ -1085,6 +1085,15 @@ IRExpr* guest_amd64_spechelper ( const HChar* function_name,

}

if (isU64(cc_op, AMD64G_CC_OP_ADDL) && isU64(cond, AMD64CondZ)) {
/* dep1 + dep2 == 0
*/
return
binop(Iop_CmpEQ64,
binop(Iop_Add64, cc_dep1, cc_dep2),
mkU64(0));
}

/*---------------- SUBQ ----------------*/

/* 0, */
Expand Down

0 comments on commit 9bcfa42

Please sign in to comment.