Static Programming Rules

Rule L.C.11

A delayed COF instruction is not allowed at LA-3 of a long loop.

Example 7-72. Delayed COF at LA-3 of a Long Loop

jmpd_dest

;not allowed

nop

 

nop

 

nop

 

loopend0

 

Rule L.C.12

A delayed COF instruction is not allowed at SA-1 of a short loop.

Example 7-73. Delayed COF at SA-1 of a Short Loop

jmpd _dest

;not allowed

loopstart0

 

nop

 

loopend0

 

7.5.11 General Looping Rules

Rule L.G.3

AMOVE-like instruction that reads the SR register is not allowed at the (LA-3), (LA-2), (LA-1), and LA of any long loop.

Example 7-74. SR Read to LA of Any Long Loop

dosetup1 label1 doen1 #5 loopstart1

label1

inc d1

move.l sr,d0;not allowed inc d2

move.l #mem_l1,r1 move.l #mem_l2,r0 loopend1

Rule L.G.4

At least one VLES is required between a MOVE-like instruction that reads the SR register and SA of any short loop.

Example 7-75. SR Read to SA of Any Short Loop

doensh0 #$10

push sr;not allowed loopstart0

inc d0 loopend0

7-40

SC140 DSP Core Reference Manual

Page 290
Image 290
Freescale Semiconductor SC140 specifications General Looping Rules, Rule L.C.11, Rule L.C.12, Rule L.G.3, Rule L.G.4