diff options
| author | Andrew Chambers <[email protected]> | 2021-10-08 01:36:55 +1300 |
|---|---|---|
| committer | Andrew Chambers <[email protected]> | 2021-10-08 01:36:55 +1300 |
| commit | 6526cddc058df5a1a84d7f4081e3f4a499642733 (patch) | |
| tree | 42d31d6df783fc97dd14e2911fbfa7d2c380c3bb /test | |
| parent | 035c38a46e86ae24269ff24f1011776200050e7f (diff) | |
More tests.
Diffstat (limited to 'test')
| -rw-r--r-- | test/test.sh | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/test/test.sh b/test/test.sh index 8d790d8..9c5e1d8 100644 --- a/test/test.sh +++ b/test/test.sh @@ -30,12 +30,26 @@ t () { echo -n "." } + for op in mov add and or sub xor do + # Special case a register variants. t "${op}b \$127, %al" - t "${op}w \$32767, %ax" # clang disagrees - t "${op}l \$2147483647, %eax" # clang disagrees - t "${op}q \$2147483647, %rax" # clang disagrees + t "${op}w \$32767, %ax" + t "${op}l \$2147483647, %eax" + t "${op}q \$2147483647, %rax" + + # immediate variants. + t "${op}b \$127, (%rbx)" + t "${op}w \$32767, (%rbx)" + t "${op}l \$2147483647, (%rbx)" + t "${op}q \$2147483647, (%rbx)" + t "${op}b \$127, %bl" + t "${op}w \$32767, %bx" + t "${op}l \$2147483647, %ebx" + t "${op}q \$2147483647, %rbx" + + # r rm variants t "${op}b (%rax), %al" t "${op}w (%rax), %ax" t "${op}l (%rax), %eax" |
