Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- .text
- .align 16
- .global process, end_process, scanp, printp, main
- main:
- pushl %ebp
- movl %esp, %ebp
- jmp process
- process:
- call l1
- l1:
- popl %eax
- addl $str - l1, %eax
- pushl %eax
- call l2
- l2:
- popl %eax
- addl $A - l2, %eax
- pushl %eax
- call l3
- l3:
- popl %eax
- addl $B - l3, %eax
- pushl %eax
- scanp:
- call scanf
- addl $12, %esp
- mov A, %ecx
- add B, %ecx
- pushl %esi
- call l4
- l4:
- popl %eax
- addl $str2 - l2, %eax
- pushl %eax
- pushl %ecx
- printp:
- call printf
- addl $8, %esp
- pop %esi
- pop %ebp
- ret
- str: .asciz "%d%d"
- str2: .asciz "%d\n"
- .align 4
- A: .int 0
- B: .int 0
- end_process:
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement