]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
SH: makecontext: Fix calculation of ARGC > 4.
authorThomas Schwinge <thomas@codesourcery.com>
Sat, 23 Jun 2012 09:28:23 +0000 (11:28 +0200)
committerThomas Schwinge <thomas@codesourcery.com>
Sat, 23 Jun 2012 09:28:23 +0000 (11:28 +0200)
stdlib/tst-setcontext and stdlib/tst-makecontext3 now pass.

ChangeLog
sysdeps/unix/sysv/linux/sh/makecontext.S

index 3ebc2aba18cddbde383285944b55bcca6a284d69..49c98fb10b731808692c8c7698b5480a4004c617 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2012-06-23  Thomas Schwinge  <thomas@codesourcery.com>
 
+       * sysdeps/unix/sysv/linux/sh/makecontext.S (__makecontext): Fix
+       calculation of ARGC > 4.
+
        * sysdeps/unix/sysv/linux/sh/makecontext.S: Add comments and give more
        meaningful names to some local labels.
 
index 9e1358dba6baaced1fde1c339ee2b22dd98d42f8..4a0207a223b581b1b0e8e2cf5a1c4fd5f6b2c74c 100644 (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