mirror of
https://github.com/GaloisInc/macaw.git
synced 2024-12-29 17:17:05 +03:00
d6060e51be
We were hitting a translation error for imul in another application - this test case is a reduced example demonstrating the problem. The root cause was that there were a few missing cases for the new signed immediate values from flexdis; this caused a fallthrough that mis-identified signed immediates as non-immediates, triggering an error.
46 lines
672 B
ArmAsm
46 lines
672 B
ArmAsm
.file "test-imul.c"
|
|
.text
|
|
.globl g
|
|
.data
|
|
.align 4
|
|
.type g, @object
|
|
.size g, 4
|
|
g:
|
|
.long -11
|
|
.text
|
|
.globl _start
|
|
.type _start, @function
|
|
_start:
|
|
.LFB0:
|
|
.cfi_startproc
|
|
pushq %rbp
|
|
.cfi_def_cfa_offset 16
|
|
.cfi_offset 6, -16
|
|
movq %rsp, %rbp
|
|
.cfi_def_cfa_register 6
|
|
#APP
|
|
# 6 "test-imul.c" 1
|
|
mov %edx,0xc(%rsp)
|
|
lea (%r12,%rax,1),%ecx
|
|
xor %eax,%eax
|
|
imul $0xffffffe8,%ebx,%ebx
|
|
add %edi,%ebx
|
|
mov %edx,%edi
|
|
|
|
# 0 "" 2
|
|
# 14 "test-imul.c" 1
|
|
movq $60,%rax
|
|
movq $0,%rdi
|
|
syscall
|
|
# 0 "" 2
|
|
#NO_APP
|
|
nop
|
|
popq %rbp
|
|
.cfi_def_cfa 7, 8
|
|
ret
|
|
.cfi_endproc
|
|
.LFE0:
|
|
.size _start, .-_start
|
|
.ident "GCC: (Ubuntu 7.3.0-27ubuntu1~18.04) 7.3.0"
|
|
.section .note.GNU-stack,"",@progbits
|