Shave off an instruction by use of conditionals.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7896 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
c267866675
commit
391f6af7ab
1 changed files with 2 additions and 4 deletions
|
@ -102,10 +102,8 @@ static inline void load_context(const void* addr)
|
|||
"ldr r0, [%0, #44] \n" /* load start pointer */
|
||||
"mov r1, #0 \n"
|
||||
"cmp r0, r1 \n" /* check for NULL */
|
||||
"beq .running \n" /* if it's NULL, we're already running */
|
||||
"str r1, [%0, #44] \n"
|
||||
"mov pc, r0 \n" /* not already running, so jump to start */
|
||||
".running: \n"
|
||||
"strne r1, [%0, #44] \n" /* if it's NULL, we're already running */
|
||||
"movne pc, r0 \n" /* not already running, so jump to start */
|
||||
: : "r" (addr) : "r0", "r1"
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue