Skip to content

Instantly share code, notes, and snippets.

@sw17ch
Last active December 16, 2015 00:09
Show Gist options
  • Save sw17ch/5345385 to your computer and use it in GitHub Desktop.
Save sw17ch/5345385 to your computer and use it in GitHub Desktop.
Loop to preload my system stack with a value of 'X'.
ldr r0, =__stack_start__
ldr r1, =__stack_end__
mov r2, 0x58585858 /* 'XXXX' */
load_stack_word:
cmp r0, r1
beq stack_initted
str r2, [r0]
add r0, r0, #4
b load_stack_word
stack_initted:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment