diff options
| author | Tim Blazytko <tim.blazytko@rub.de> | 2015-07-29 20:42:59 +0200 |
|---|---|---|
| committer | Tim Blazytko <tim.blazytko@rub.de> | 2015-07-29 20:42:59 +0200 |
| commit | 23e110db72ee6fd06059c33b14d7af1f61311b63 (patch) | |
| tree | 986cd29c95fb43379978319bb0845d400b42db03 | |
| parent | d6fc3585a9e7eb623d542fe0149a122bfcc00700 (diff) | |
| download | miasm-23e110db72ee6fd06059c33b14d7af1f61311b63.tar.gz miasm-23e110db72ee6fd06059c33b14d7af1f61311b63.zip | |
TranslatorZ3: added translation for udiv, imod and umod
| -rw-r--r-- | miasm2/ir/translators/z3_ir.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/miasm2/ir/translators/z3_ir.py b/miasm2/ir/translators/z3_ir.py index d908ac5a..af4544a9 100644 --- a/miasm2/ir/translators/z3_ir.py +++ b/miasm2/ir/translators/z3_ir.py @@ -169,6 +169,12 @@ class TranslatorZ3(Translator): res = res << arg elif expr.op == "idiv": res = res / arg + elif expr.op == "udiv": + res = z3.UDiv(res, arg) + elif expr.op == "imod": + res = res % arg + elif expr.op == "umod": + res = z3.URem(res, arg) else: raise NotImplementedError("Unsupported OP yet: %s" % expr.op) elif expr.op == 'parity': |