diff options
| author | Pierre Lalet <pierre@droids-corp.org> | 2015-11-15 20:40:43 +0100 |
|---|---|---|
| committer | Pierre Lalet <pierre@droids-corp.org> | 2015-11-15 20:40:43 +0100 |
| commit | 5764a1fb42cc3e50cb4c322cc3146375fbce84ef (patch) | |
| tree | c47c2edcd5733162e5b15a7add35cbd55c1f5aed | |
| parent | e427a54c96f04a6cace7f4be0f95cba625df5895 (diff) | |
| parent | 40e12926ceb33ead77197b6893dc40e36dc5e717 (diff) | |
| download | miasm-5764a1fb42cc3e50cb4c322cc3146375fbce84ef.tar.gz miasm-5764a1fb42cc3e50cb4c322cc3146375fbce84ef.zip | |
Merge pull request #268 from serpilliere/fix_rdtsc
Sem/x86: fix rdtsc
| -rw-r--r-- | miasm2/arch/x86/sem.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/miasm2/arch/x86/sem.py b/miasm2/arch/x86/sem.py index 0e83de8c..51bf5d3b 100644 --- a/miasm2/arch/x86/sem.py +++ b/miasm2/arch/x86/sem.py @@ -2538,9 +2538,9 @@ def hlt(ir, instr): def rdtsc(ir, instr): e = [] e.append(m2_expr.ExprAff(tsc1, tsc1 + m2_expr.ExprInt32(1))) - e.append(m2_expr.ExprAff(tsc2, tsc2 + ExprCond(tsc1 - tsc1.mask, - ExprInt32(0), - ExprInt32(1)))) + e.append(m2_expr.ExprAff(tsc2, tsc2 + m2_expr.ExprCond(tsc1 - tsc1.mask, + m2_expr.ExprInt32(0), + m2_expr.ExprInt32(1)))) e.append(m2_expr.ExprAff(mRAX[32], tsc1)) e.append(m2_expr.ExprAff(mRDX[32], tsc2)) return e, [] |