1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-30 22:43:12 +03:00

SH: makecontext: Fix calculation of ARGC > 4.

stdlib/tst-setcontext and stdlib/tst-makecontext3 now pass.
This commit is contained in:
Thomas Schwinge
2012-06-23 11:28:23 +02:00
parent af1bce34ef
commit 2a649725b9
2 changed files with 4 additions and 1 deletions

View File

@ -36,7 +36,7 @@ ENTRY(__makecontext)
mov.l @(oSS_SP,r4), r1 /* r1 <- ucb->stack_base */
mov.l @(oSS_SIZE,r4), r2 /* r2 <- ucb->stack_size */
add r1, r2 /* r2 <- stack_top */
cmp/gt r6, r3 /* 4 > argc? */
cmp/gt r3, r6 /* argc > 4? */
bf/s 1f
shlr2 r2 /* r2 <- stack_top / 4 */
sub r6, r2