Yes, It is a test code.
I want to pass more than 4 parameters to assemble code, so I need to pass them by stack. And I want to use R4-R8 , so I should protect save them before I change its value , and I push them into stack with code below:
mov R12,SP
STMDB SP!,{R4-R7}
STR R1, [R0] ,#4
STR R2, [R0] ,#4
STR R3, [R0] ,#4
mov pc,lr
END
what can I do? Thanks in advance!
Bye the way, it will corrupt when I stmdb more register and write back to sp. Such as
STMDB SP!,{R4-R11}