]> git.sur5r.net Git - cc65/blob - libsrc/runtime/pushb.s
Added dump of the file list
[cc65] / libsrc / runtime / pushb.s
1 ;
2 ; Ullrich von Bassewitz, 31.08.1998
3 ;
4 ; CC65 runtime: Push word from stack
5 ;
6
7         .export         pushb, pushbidx
8         .import         pushax
9         .importzp       ptr1                          
10
11 pushbidx:
12         sty     ptr1
13         clc
14         adc     ptr1
15         bcc     pushb
16         inx
17 pushb:  sta     ptr1
18         stx     ptr1+1
19         ldx     #0              ; Load index/high byte
20         lda     (ptr1,x)
21         bpl     L1
22         dex                     ; Make high byte FF
23 L1:     jmp     pushax
24