Skip to content

Commit

Permalink
add x64 arch + full x86/64 SSE decoder
Browse files Browse the repository at this point in the history
  • Loading branch information
bdcht committed Nov 23, 2014
1 parent b7dc45e commit b97e480
Show file tree
Hide file tree
Showing 22 changed files with 4,835 additions and 254 deletions.
3 changes: 0 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
tags
*.pyc
<<<<<<< HEAD
=======
*.swp
>>>>>>> develop
build/
tests/
8 changes: 7 additions & 1 deletion amoco/arch/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,13 @@ def decode(self,istr,endian=1,i=None,ival=None):
if type(v)==type(lambda:1): v=v(b)
kargs[k] = v
# and call hooks:
self.hook(obj=i,**kargs)
try:
self.hook(obj=i,**kargs)
except InstructionError:
# clean up:
i.bytes = i.bytes[:-len(bs)]
for k in self.iattr.iterkeys(): delattr(i,k)
raise InstructionError(i)
return i

def encode(self,i):
Expand Down
Empty file added amoco/arch/x64/__init__.py
Empty file.
Loading

0 comments on commit b97e480

Please sign in to comment.