radare2/libr/asm/t/lops.sh
pancake 5225c95d18 Fix 'ad', 'a8' and add more test cases for x86/arm assemblers
Fix 'a8' command
Honor argument in 'ad'
Add more tests for x86 and arm assemblers
2013-02-21 11:31:04 +01:00

18 lines
267 B
Bash

#!/bin/sh
a=0
b=0
arch=$1
[ -z "$arch" ] && arch=x86
while : ; do
x=`printf "%02x%02x000000000" $b $a`
printf "$x "
rasm2 -e -a $arch -d $x 2>/dev/null | head -n1
if [ "$a" = 255 ]; then
a=0
b=$(($b+1))
[ "$b" = 256 ] && break
else
a=$(($a+1))
fi
done