talk-2019-10-OOPSLA19/src/fib7/fib7.s

19 lines
530 B
ArmAsm

0000000000000615 <fib7>:
615: sub $0x28,%rsp ; Alloc stack
619: movl $0x1,(%rsp) ; fibo[0]
620: movl $0x1,0x4(%rsp) ; fibo[1]
628: mov %rsp,%rax ; BEGIN FOR
62b: lea 0x18(%rax),%rcx
62f: mov (%rax),%edx
631: add 0x4(%rax),%edx
634: mov %edx,0x8(%rax)
637: add $0x4,%rax
63b: cmp %rcx,%rax
63e: jne 62f <fib7+0x1a> ; END FOR
640: mov 0x1c(%rsp),%esi
644: lea 0xb9(%rip),%rdi
64b: mov $0x0,%eax
650: callq 520 <printf@plt>
655: add $0x28,%rsp ; Restore rsp
659: retq