aboutsummaryrefslogtreecommitdiff
path: root/amforth-6.5/msp430/words/swap.asm
blob: 7950f180f34342635622c2d199bffefc1dbeae80 (plain)
1
2
3
4
5
6
;C XT_SWAP     x1 x2 -- x2 x1    swap top two items
        CODEHEADER(XT_SWAP,4,"swap")
        MOV     @PSP,W          ; 2
        MOV     TOS,0(PSP)      ; 4
        MOV     W,TOS           ; 1
        NEXT                    ; 4