cs205-lecture-examples

Example codes used during Harvard CS205 lectures
git clone https://git.0xfab.ch/cs205-lecture-examples.git
Log | Files | Refs | README | LICENSE

saxpy.s (435B)


      1 	.file	"saxpy.c"
      2 	.intel_syntax noprefix
      3 	.text
      4 	.globl	saxpy
      5 	.type	saxpy, @function
      6 saxpy:
      7 .LFB0:
      8 	.cfi_startproc
      9 	test	rdx, rdx
     10 	je	.L1
     11 	mov	eax, 0
     12 .L3:
     13 	movaps	xmm1, xmm0
     14 	mulss	xmm1, DWORD PTR [rdi+rax*4]
     15 	addss	xmm1, DWORD PTR [rsi+rax*4]
     16 	movss	DWORD PTR [rsi+rax*4], xmm1
     17 	add	rax, 1
     18 	cmp	rdx, rax
     19 	jne	.L3
     20 .L1:
     21 	ret
     22 	.cfi_endproc
     23 .LFE0:
     24 	.size	saxpy, .-saxpy
     25 	.ident	"GCC: (GNU) 11.2.0"
     26 	.section	.note.GNU-stack,"",@progbits