mirror of
https://github.com/yuzu-mirror/unicorn.git
synced 2026-04-05 22:45:40 +00:00
make cleanup
This commit is contained in:
parent
4d5738eeb5
commit
186540e160
38 changed files with 1149 additions and 800 deletions
|
|
@ -21,7 +21,7 @@ def hook_block(uc, address, size, user_data):
|
|||
|
||||
# callback for tracing instructions
|
||||
def hook_code(uc, address, size, user_data):
|
||||
print(">>> Tracing instruction at 0x%x, instruction size = %u" %(address, size))
|
||||
print(">>> Tracing instruction at 0x%x, instruction size = 0x%x" %(address, size))
|
||||
|
||||
|
||||
# Test ARM
|
||||
|
|
@ -46,7 +46,7 @@ def test_arm():
|
|||
mu.hook_add(UC_HOOK_BLOCK, hook_block)
|
||||
|
||||
# tracing all instructions with customized callback
|
||||
mu.hook_add(UC_HOOK_CODE, hook_code)
|
||||
mu.hook_add(UC_HOOK_CODE, hook_code, begin=ADDRESS, end=ADDRESS)
|
||||
|
||||
# emulate machine code in infinite time
|
||||
mu.emu_start(ADDRESS, ADDRESS + len(ARM_CODE))
|
||||
|
|
@ -100,5 +100,5 @@ def test_thumb():
|
|||
|
||||
if __name__ == '__main__':
|
||||
test_arm()
|
||||
print("=" * 20)
|
||||
print("=" * 26)
|
||||
test_thumb()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue