Outer Loop Conditionally Executed With Inner Loop
6-145
Optimizing Assembly Code via Linear Assembly
Example 6–77. Linear Assembly for FIR With Outer Loop Conditionally Executed
With Inner Loop (With Functional Units)(Continued)
MPY
.M2
h67,x67,p06
; p06 = h[i+6]*x[j+i+6]
ADD
.L1X
p06,sum05,sum06
; sum0 += p06
MPYH
.M2
h67,x67,p07
; p07 = h[i+7]*x[j+i+7]
ADD
.L1X
p07,sum06,sum07
; sum0 += p07
[!sctr]
MVK
.S1
4,sctr
; reset store lp cntr
[pctr]
SUB
.S1
pctr,1,pctr
; dec pointer reset lp cntr
[!pctr]
SUB
.S2
x,rstx2,x
; reset x ptr
[!pctr]
SUB
.S1
x_1,rstx1,x_1
; reset x_1 ptr
[!pctr]
SUB
.S1
h,rsth1,h
; reset h ptr
[!pctr]
SUB
.S2
h_1,rsth2,h_1
; reset h_1 ptr
[!pctr]
MVK
.S1
4,pctr
; reset pointer reset lp cntr
[octr]
SUB
.S2
octr,1,octr
; dec outer lp cntr
[octr]
B
.S2
LOOP
; Branch outer loop
.endproc