STREAMS 4
TYPE DOUBLE
FLOPS 2
BYTES 24
LOADS 2
STORES 1
INSTR_LOOP 19
INSTR_CONST 13
UOPS 19

li r10, 8           # eight (4x2) elements per loop iteration
divd r10, r3, r10   # r3 holds loop limit, divide by elements per loop iteration
mtctr r10           # move to count register
li r8, 0            # load immediate value of 0 into r7 (used as offset in addressing)
li r9, 16           # load immediate value of 16 into r8 (used as offset in addressing)
li r10, 32           # load immediate value of 32 into r9 (used as offset in addressing)
li 11, 48          # load immediate value of 48 into r10 (used as offset in addressing)


xvsubdp 2, 2, 2    # set to zero
xvsubdp 5, 5, 5    # set to zero
xvsubdp 8, 8, 8    # set to zero
xvsubdp 11, 11, 11 # set to zero

LOOP 8

lxvd2x 0, STR0, r8
lxvd2x 1, STR1, r8
xvmaddadp 0, 1, 2
stxvd2x 0, STR2, r8

lxvd2x 3, STR0, r9
lxvd2x 4, STR1, r9
xvmaddadp 3, 4, 5
stxvd2x 3, STR2, r9

lxvd2x 6, STR0, r10
lxvd2x 7, STR1, r10
xvmaddadp 6, 7, 8
stxvd2x 6, STR2, r10

lxvd2x 9, STR0, 11
lxvd2x 10, STR1, 11
xvmaddadp 9, 10, 11
stxvd2x 9, STR2, 11

addi STR0, STR0, 64
addi STR1, STR1, 64
addi STR2, STR2, 64
