Advertisement
Guest User

Untitled

a guest
Jan 23rd, 2017
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. .text
  2. .global main
  3. main:
  4. movl $0, %ebx
  5. movl $0, %esi
  6.  
  7. LoopBegin:
  8. call readi32
  9. jc LoopEnd
  10. testl $1, %eax
  11.  
  12. jnz LoopMid
  13. addl %eax, %esi
  14. subl %eax, %ebx
  15. LoopMid:
  16. addl %eax, %ebx
  17. jmp LoopBegin
  18. LoopEnd:
  19.  
  20. movl %esi, %eax
  21. call writei32
  22. call nl
  23. movl %ebx, %eax
  24. call writei32
  25. call nl
  26. call finish
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement