Advertisement
Guest User

Untitled

a guest
Jan 10th, 2016
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. void main()
  2. {
  3. int i;
  4. const int n = 10;
  5. double res;
  6. double a[n] = { 0.75,6.46,3.72,5.07,4.09,0.53,9.45,1.65,4.41,1.29 };
  7. __asm
  8. {
  9. mov edx, n
  10. lea ebx, a
  11. MOV eSI, ebx
  12. add eSI, 24
  13. mov ecx, edx
  14. shr ecx, 1
  15. dec ecx
  16. FLD QWORD PTR[ebx + 8]
  17. @sum:
  18. FADD QWORD PTR[eSI]
  19. add eSI, 16
  20. loop @sum
  21. FSTP res
  22. }
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement