section 7 - Index of

section 7 - Index of section 7 - Index of

11.07.2015 Views

DOStart Hardware LoopDOExample:DO #cnt1, END1DO #cnt2, END2;begin outer DO loop;begin inner DO loopMOVE A,X:(RO)+END2ADD A,S X:(R1 )+,XOEND1;Iast instruction in inner loop;(in outer loop);Iast instruction in outer loop;first instruction after outer loopExplanation of Example: This example illustrates a nested DO loop. The outer DO loopwill be executed "cnt1" times while the inner DO loop will be executed ("cnt1" * "cnt2")times. Note that the labels END1 and END2 are located at the first instruction past the endof the DO loop, as mentioned above, and are nested properly.Condition Codes:15 14 13 12 11 10 9 8 7 6 5 4 3 2I LF I DM I T I ** I 81 I 80 I 11 I 10 I s I L E I u N I zCCRoFor source operand A or S:LF - Set when a DO loop is in progressS -L -Computed according to the definition. See Notes on page A-97.Set if data limiting occurred. See Notes on page A-97.For other source operands:-LF -Set when a DO loop is in progress

DOStart Hardware LoopDOInstruction Format:DO X:ea, exprDO Y:ea, exprOpcode:23 20 19 16 15 8 7o 0 0 010 1 1 o I 0 1oSO 010000ABSOLUTE ADDRESS EXTENSIONInstruction Fields:ea=6-bit Effective Address=MMMRRR,expr=16-bit Absolute Address in 24-bit extension wordEffectiveAddressing Mode MMMRRR Memory SpaceS(Rn)-Nn o 0 o r r r X Memory(Rn)+Nn 0 1 r r r Y Memory(Rn)-1 o r r r(Rn)+o 1 1 r r r(Rn)1 0 o r r r(Rn+Nn)1 0 1 r r r-(Rn)1 1 1 r r rwhere "rrr" refers to an address register RO-R?Timing: 6+mv oscillator clock cyclesMemory: 2 program words01-

DOStart Hardware LoopDOInstruction Format:DO X:ea, exprDO Y:ea, exprOpcode:23 20 19 16 15 8 7o 0 0 010 1 1 o I 0 1oSO 010000ABSOLUTE ADDRESS EXTENSIONInstruction Fields:ea=6-bit Effective Address=MMMRRR,expr=16-bit Absolute Address in 24-bit extension wordEffectiveAddressing Mode MMMRRR Memory SpaceS(Rn)-Nn o 0 o r r r X Memory(Rn)+Nn 0 1 r r r Y Memory(Rn)-1 o r r r(Rn)+o 1 1 r r r(Rn)1 0 o r r r(Rn+Nn)1 0 1 r r r-(Rn)1 1 1 r r rwhere "rrr" refers to an address register RO-R?Timing: 6+mv oscillator clock cyclesMemory: 2 program words01-

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!