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>] sar <ar><dma> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
SYNTAX      DIRECT   [<LABEL>] SAR <AR><dma>
            INDIRECT [<LABEL>] SACL <AR>,{ind}[,<next ARP>]

OPERANDS    0 . dma . 127; 0 . next ARP . 7;
            0 . auxiliary register AR . 7.

EXECUTION   (PC) + 1 . PC
            (AR) . dma

DESCRIPTION The contents of the designated auxiliary register (AR) are
            stored in the addressed data memory location.

            When modifying the contents of the current auxiliary register
            in the indirect addressing mode, SAR ARn (where n = ARP)
            stores the value of the auxiliary register contents before it
            is incremented, decremented, or indexed by AR0.

WORDS       1

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

            15 14 13 12 11 10  9  8  7  6  5  4  3  2  1  0
            +-----------------------------------------------+
            |0  1  1  1  0|   AR   | 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   |  2+d  |  1+p  | 3+d+p  |   -   |   -   |
            |-------+-------+-------+--------+-------+-------|
     'C25   |   1   |  1+d  |  1+p  | 2+d+p  |   1   |  1+d  |
            |------------------------------------------------|
            |    Cycle Timings for a Repeat Instruction      |
            |------------------------------------------------|
      '20   |   n   | 2n+nd |  n+p  | 3n+nd+p|   -   |   -   |
            |-------+-------+-------+--------+-------+-------|
     'C25   |   n   |  n+nd |  n+p  |1+n+nd+p|   n   | n+nd  |
            +------------------------------------------------+



EXAMPLE     SAR   AR0,DAT30   (DP = 6)
            or
            SAR   AR0,*       If current auxiliary register contains 798.

                     BEFORE             AFTER

                    AR0 >37           AR0 >37
                  dm798 >18         dm798 >37


EXAMPLE     LARP  AR0
            SAR   AR0,*0+

                     BEFORE             AFTER

                   AR0 >401          AR0 >802
                dm1025   >0       dm1025 >401

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