radare2-extras
radare2-extras copied to clipboard
Unicorn initialization parameters change for ARM
For the ARM architecture, it appears that the following line no longer works
err = uc_open (UC_ARCH_ARM, bits==64? UC_MODE_64: UC_MODE_32, &uh);
instead I tried
err = uc_open (bits==64? UC_ARCH_ARM64: UC_ARCH_ARM, UC_MODE_ARM, &uh);
which works better. My version of unicorn (build from latest source) won't intialize with the former statement.
we may want to look into the second parameters which allows for THUMB mode, but then what happens with mixed modes, I'm not sure.