diff --git a/libsrc/runtime/incsp3.s b/libsrc/runtime/incsp3.s index 90dca0b96..6c91bfceb 100644 --- a/libsrc/runtime/incsp3.s +++ b/libsrc/runtime/incsp3.s @@ -1,20 +1,23 @@ ; -; Ullrich von Bassewitz, 25.10.2000 +; Ullrich von Bassewitz, 2003-05-04 ; ; CC65 runtime: Increment the stackpointer by 3 ; .export incsp3 - .import addysp + .importzp sp .proc incsp3 - ldy #3 - jmp addysp + lda sp + clc + adc #3 + sta sp + bcs @L1 + rts + +@L1: inc sp+1 + rts .endproc - - - - diff --git a/libsrc/runtime/incsp4.s b/libsrc/runtime/incsp4.s index 125c533e7..0d320fdf2 100644 --- a/libsrc/runtime/incsp4.s +++ b/libsrc/runtime/incsp4.s @@ -1,20 +1,23 @@ ; -; Ullrich von Bassewitz, 25.10.2000 +; Ullrich von Bassewitz, 2003-05-04 ; ; CC65 runtime: Increment the stackpointer by 4 ; .export incsp4 - .import addysp + .importzp sp .proc incsp4 - ldy #4 - jmp addysp + lda sp + clc + adc #4 + sta sp + bcs @L1 + rts + +@L1: inc sp+1 + rts .endproc - - - - diff --git a/libsrc/runtime/incsp5.s b/libsrc/runtime/incsp5.s index df239cf21..963c0b3aa 100644 --- a/libsrc/runtime/incsp5.s +++ b/libsrc/runtime/incsp5.s @@ -1,20 +1,24 @@ ; -; Ullrich von Bassewitz, 25.10.2000 +; Ullrich von Bassewitz, 2003-05-04 ; ; CC65 runtime: Increment the stackpointer by 5 ; .export incsp5 - .import addysp + .importzp sp .proc incsp5 - ldy #5 - jmp addysp + lda sp + clc + adc #5 + sta sp + bcs @L1 + rts + +@L1: inc sp+1 + rts .endproc - - - - + diff --git a/libsrc/runtime/incsp6.s b/libsrc/runtime/incsp6.s index a7ab932dd..5221138fc 100644 --- a/libsrc/runtime/incsp6.s +++ b/libsrc/runtime/incsp6.s @@ -1,20 +1,24 @@ ; -; Ullrich von Bassewitz, 25.10.2000 +; Ullrich von Bassewitz, 2003-05-04 ; ; CC65 runtime: Increment the stackpointer by 6 ; .export incsp6 - .import addysp + .importzp sp .proc incsp6 - ldy #6 - jmp addysp + lda sp + clc + adc #6 + sta sp + bcs @L1 + rts + +@L1: inc sp+1 + rts .endproc - - - - + diff --git a/libsrc/runtime/incsp7.s b/libsrc/runtime/incsp7.s index 417700fe9..48fc91a69 100644 --- a/libsrc/runtime/incsp7.s +++ b/libsrc/runtime/incsp7.s @@ -1,20 +1,24 @@ ; -; Ullrich von Bassewitz, 25.10.2000 +; Ullrich von Bassewitz, 2003-05-04 ; ; CC65 runtime: Increment the stackpointer by 7 ; .export incsp7 - .import addysp + .importzp sp .proc incsp7 - ldy #7 - jmp addysp + lda sp + clc + adc #7 + sta sp + bcs @L1 + rts + +@L1: inc sp+1 + rts .endproc - - - - + diff --git a/libsrc/runtime/incsp8.s b/libsrc/runtime/incsp8.s index 3ec15202e..9baf5185c 100644 --- a/libsrc/runtime/incsp8.s +++ b/libsrc/runtime/incsp8.s @@ -1,17 +1,24 @@ ; -; Ullrich von Bassewitz, 25.10.2000 +; Ullrich von Bassewitz, 2003-05-04 ; ; CC65 runtime: Increment the stackpointer by 8 ; .export incsp8 - .import addysp + .importzp sp .proc incsp8 - ldy #8 - jmp addysp + lda sp + clc + adc #8 + sta sp + bcs @L1 + rts + +@L1: inc sp+1 + rts .endproc - +