Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- TMS320C2x DSP - syntax direct [<label>] mar <dma> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
SYNTAX      DIRECT   [<LABEL>] MAR <dma>
            INDIRECT [<LABEL>] MAR {ind}[,<next ARP>]

OPERANDS    0 . dma . 127; 0 . next ARP . 7.

EXECUTION   (PC) + 1 . PC
            Modifies ARP, AR(ARP) as specified by the indirect addressing
            field (acts as a NOP in direct addressing).

DESCRIPTION The MAR instruction acts as a no-operation instruction in the
            direct addressing mode. In the indirect addressing mode, the
            auxiliary registers and the ARP are modified; however, no use
            is made of the memory being referenced. MAR is used only to
            modify the auxiliary registers or the ARP. The old ARP is
            copied to the ARB field of status register ST1. Note that any
            operation that MAR performs can also be performed with any
            instruction that permits indirect addressing. ARP may also be
            loaded by an LST instruction.

            In the direct addressing mode, MAR is a NOP. Also, the
            instruction LARP is a subset of MAR (i.e. MAR *,4 performs the
            same function as LARP 4).

WORDS       1

ENCODING    15 14 13 12 11 10  9  8  7  6  5  4  3  2  1  0
            +-----------------------------------------------+
            |0  1  0  1  0  1  0  1| 0| data memory address | DIRECT
            +-----------------------------------------------+

            15 14 13 12 11 10  9  8  7  6  5  4  3  2  1  0
            +-----------------------------------------------+
            |0  1  0  1  0  1  0  1| 1| see indirect fields | INDIRECT
            +-----------------------------------------------+

CYCLES

            +------------------------------------------------+
            |    Cycle Timings for a Single Instruction      |
            |------------------------------------------------|
            | PI/DI | PI/DE | PE/DI | PE/DE  | PR/DI | PR/DE |
            |-------+-------+-------+--------+-------+-------|
      '20   |   1   |   1   |  1+p  |  1+p   |   -   |   -   |
            |-------+-------+-------+--------+-------+-------|
     'C25   |   1   |   1   |  1+p  |  1+p   |   1   |   1   |
            |------------------------------------------------|
            |    Cycle Timings for a Repeat Instruction      |
            |------------------------------------------------|
      '20   |   n   |   n   |  n+p  |  n+p   |   -   |   -   |
            |-------+-------+-------+--------+-------+-------|
     'C25   |   n   |   n   |  n+p  |  n+p   |   n   |   n   |
            +------------------------------------------------+



EXAMPLE     MAR   *,1         Load the ARP with 1

             BEFORE             AFTER

            ARP   0           ARP   1

EXAMPLE     MAR   *,-         Decrement current auxiliary register (in
                              this case AR1)

             BEFORE             AFTER

            AR1 >35           AR1 >34

EXAMPLE     MAR   *+,5        Increment current auxiliary register (AR1)
                              and load ARP with 5

             BEFORE             AFTER

            AR1 >34           AR1 >35
            ARP   1           ARP   5

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson