.global _start

.text

_start:
    @ Set up initial values
    mov r0, #10
    mov r1, #20
    mov r2, #30
    mov r3, #40

    @ Push values onto the stack
    push {r0, r1, r2, r3}

    @ At this point, the stack contains 40, 30, 20, 10

    @ Pop values back from the stack into different registers
    pop {r4, r5, r6, r7}

    @ At this point, r4 = 10, r5 = 20, r6 = 30, r7 = 40

    @ Exit the program
    mov r7, #1  @ syscall number for exit
    swi 0       @ make the syscall to exit the program

