diff options
| author | serpilliere <serpilliere@users.noreply.github.com> | 2015-11-17 14:18:16 +0100 |
|---|---|---|
| committer | serpilliere <serpilliere@users.noreply.github.com> | 2015-11-17 14:18:16 +0100 |
| commit | a49419dd5e16283b1663181a47cdc85b7eff14dc (patch) | |
| tree | eed2791c9c96039c6603d0173646eb4265a85366 /miasm2/jitter/jitcore_python.py | |
| parent | c0826fefbbcd00c60f0e9f27dcac92c98fcb9d8e (diff) | |
| parent | bf4c21011c8396b939e147615d12998a11c91dcd (diff) | |
| download | miasm-a49419dd5e16283b1663181a47cdc85b7eff14dc.tar.gz miasm-a49419dd5e16283b1663181a47cdc85b7eff14dc.zip | |
Merge pull request #277 from commial/fix-x86-xchg
Fix x86 xchg
Diffstat (limited to 'miasm2/jitter/jitcore_python.py')
| -rw-r--r-- | miasm2/jitter/jitcore_python.py | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/miasm2/jitter/jitcore_python.py b/miasm2/jitter/jitcore_python.py index 96db3a2b..e29c81c0 100644 --- a/miasm2/jitter/jitcore_python.py +++ b/miasm2/jitter/jitcore_python.py @@ -57,10 +57,8 @@ class JitCore_Python(jitcore.JitCore): def load(self): "Preload symbols according to current architecture" - symbols_init = {} - for r in self.ir_arch.arch.regs.all_regs_ids_no_alias: - symbols_init[r] = self.ir_arch.arch.regs.regs_init[r] - + symbols_init = {r:m2_expr.ExprInt(0, size=r.size) + for r in self.ir_arch.arch.regs.all_regs_ids_no_alias} self.symbexec = symbexec(self.ir_arch, symbols_init, func_read = self.func_read, func_write = self.func_write) @@ -76,12 +74,11 @@ class JitCore_Python(jitcore.JitCore): return m2_expr.ExprInt(int(value[::-1].encode("hex"), 16), expr_mem.size) - def func_write(self, symb_exec, dest, data, mem_cache): + def func_write(self, symb_exec, dest, data): """Memory read wrapper for symbolic execution @symb_exec: symbexec instance @dest: ExprMem instance - @data: Expr instance - @mem_cache: dict""" + @data: Expr instance""" # Get the content to write data = expr_simp(data) |