mirror of
https://github.com/radareorg/radare2.git
synced 2025-02-13 18:32:56 +00:00
Correction of ESIL code generated for ROL, ROR and OR instructions on X86 (#5873)
* Esil equivalent of x86 cmp instruction now set the overflow flag. * Fixed ESIL code generated for ROL instruction. * Fixed ESIL code generated for OR instruction.
This commit is contained in:
parent
ccda50b1a2
commit
c02be8da7d
@ -642,8 +642,8 @@ static void anop_esil (RAnal *a, RAnalOp *op, ut64 addr, const ut8 *buf, int len
|
||||
// - Set flags
|
||||
{
|
||||
char *src = getarg (&gop, 1, 0, NULL);
|
||||
char *dst = getarg (&gop, 0, 1, NULL);
|
||||
esilprintf (op, "%s,%s,<<<,%s", src, dst, dst);
|
||||
char *dst = getarg (&gop, 0, 0, NULL);
|
||||
esilprintf (op, "%s,%s,<<<,%s,=", src, dst, dst);
|
||||
free (src);
|
||||
free (dst);
|
||||
}
|
||||
@ -654,8 +654,8 @@ static void anop_esil (RAnal *a, RAnalOp *op, ut64 addr, const ut8 *buf, int len
|
||||
// - Set flags
|
||||
{
|
||||
char *src = getarg (&gop, 1, 0, NULL);
|
||||
char *dst = getarg (&gop, 0, 1, NULL);
|
||||
esilprintf (op, "%s,%s,>>>,%s", src, dst, dst);
|
||||
char *dst = getarg (&gop, 0, 0, NULL);
|
||||
esilprintf (op, "%s,%s,>>>,%s,=", src, dst, dst);
|
||||
free (src);
|
||||
free (dst);
|
||||
}
|
||||
@ -1059,8 +1059,9 @@ static void anop_esil (RAnal *a, RAnalOp *op, ut64 addr, const ut8 *buf, int len
|
||||
// mistake.
|
||||
{
|
||||
char *src = getarg (&gop, 1, 0, NULL);
|
||||
char *dst = getarg (&gop, 0, 0, NULL);
|
||||
esilprintf (op, "%s,%s,|=,$s,sf,=,$z,zf,=,$p,pf,=,$0,of,=,$0,cf,=", src, dst);
|
||||
char *dst = getarg (&gop, 0, 1, "|");
|
||||
esilprintf (op, "%s,%s,$s,sf,=,$z,zf,=,$p,pf,=,$0,of,=,$0,cf,=",
|
||||
src, dst);
|
||||
free (src);
|
||||
free (dst);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user