Advertisement
Guest User

Untitled

a guest
Jan 24th, 2019
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. movl    $0, %ebx
  3. movl    $0, %esi
  4. iteration:
  5.     читаем число
  6.     если eof — eof
  7.     закидываем в %ebx
  8.     testl   %eax, $1
  9.     jz      odd
  10. even:
  11.     addl    %ebx, %esi
  12.     jmp     iteration
  13. odd:
  14.     addl    %ebx, %edx
  15.     jmp     iteration
  16. eof:
  17.     movl    %edx, %eax
  18.     call    writei32
  19.     movl    %esi, %eax
  20.     call    writei32
  21.     call    finish
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement