Skip to content

Commit

Permalink
Fix another test
Browse files Browse the repository at this point in the history
  • Loading branch information
twizmwazin committed Nov 20, 2023
1 parent 83ff5fc commit 2271971
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
1 change: 0 additions & 1 deletion pyvex/arches.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ def translate_register_name(self, offset, size=None): # pylint: disable=unused-
for (arch, reg), offset2 in subregister_map.items():
if arch == self.vex_name_small and offset2 == offset:
return reg
print("nope")
return str(offset)

def get_register_offset(self, name: str) -> int:
Expand Down
3 changes: 1 addition & 2 deletions pyvex/lifting/util/instr_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
import bitstring

from pyvex.expr import IRExpr, RdTmp
from pyvex.vex_ffi import guest_offsets

from .lifter_helper import ParseError
from .syntax_wrapper import VexValue
Expand Down Expand Up @@ -256,7 +255,7 @@ def constant(self, val, ty):

@staticmethod
def _lookup_register(arch, reg):
return guest_offsets.get((arch.name.lower(), reg))
return arch.translate_register_name(reg)

def get(self, reg, ty):
"""
Expand Down

0 comments on commit 2271971

Please sign in to comment.