;SoftMMU Implementation - 6502 support ;===================================== ;---- ;Name ;---- name_6502: .byte "65xx wrapper",$00 ;--------- ;Page swap ;--------- xpage_6502: ;simply slide the window :) lda banklo ;3 sta $01,x ;4 cli ;2 pla ;4 tay ;2 pla ;4 rts ;6 ;== 21 cycles ;---------- ;Allocation ;---------- ****OLD CODE**** ;basically a wrapper for mpalloc xalloc_6502: ;make sure we're not trying >256 pages lda tmpzp+4 beq + jmp xalloc_trynext + stx tmpzp+5 sty tmpzp+6 lda tmpzp+3 ldx lk_ipid ldy #0 jsr mpalloc bcs + ;---------------- ;Context switches ;---------------- ;Don't need to monitor them. #define getcontext_6502 $0000 #define losecontext_6502 $0000