Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libc/arch/vax/sys Make __curbrk & __minbrk hidden.



details:   https://anonhg.NetBSD.org/src/rev/b485a0eb3db6
branches:  trunk
changeset: 788691:b485a0eb3db6
user:      matt <matt%NetBSD.org@localhost>
date:      Thu Jul 18 12:27:01 2013 +0000

description:
Make __curbrk & __minbrk hidden.

diffstat:

 lib/libc/arch/vax/sys/brk.S  |  13 ++++++++-----
 lib/libc/arch/vax/sys/sbrk.S |  15 +++++++++------
 2 files changed, 17 insertions(+), 11 deletions(-)

diffs (80 lines):

diff -r 99cc390f8e88 -r b485a0eb3db6 lib/libc/arch/vax/sys/brk.S
--- a/lib/libc/arch/vax/sys/brk.S       Thu Jul 18 12:21:52 2013 +0000
+++ b/lib/libc/arch/vax/sys/brk.S       Thu Jul 18 12:27:01 2013 +0000
@@ -31,23 +31,26 @@
 
 #if defined(SYSLIBC_SCCS) && !defined(lint)
        /* .asciz "@(#)brk.s    8.1 (Berkeley) 6/4/93" */
-RCSID("$NetBSD: brk.S,v 1.13 2011/01/25 02:38:15 matt Exp $")
+RCSID("$NetBSD: brk.S,v 1.14 2013/07/18 12:27:01 matt Exp $")
 #endif /* SYSLIBC_SCCS and not lint */
 
-       .globl  CURBRK
+       .globl  _C_LABEL(__curbrk)
        .globl  _C_LABEL(__minbrk)
+       .hidden _C_LABEL(__curbrk)
+       .hidden _C_LABEL(__minbrk)
 
 #ifdef WEAK_ALIAS
 WEAK_ALIAS(brk, _brk)
 #endif
 
 ENTRY(_brk, 0)
-       cmpl    _C_LABEL(__minbrk),4(%ap)       # gtr > _end 
+       moval   _C_LABEL(__minbrk),%r5          # gtr > _end 
+       cmpl    (%r5),4(%ap)                    # gtr > _end 
        blequ   1f                              #   is fine
-       movl    _C_LABEL(__minbrk),4(%ap)       # shrink back to _end
+       movl    (%r5),4(%ap)                    # shrink back to _end
 1:     chmk    $ SYS_break                     # do it
        jcs     err
-       movl    4(%ap),CURBRK
+       movl    4(%ap),_C_LABEL(__curbrk)
        clrl    %r0
        ret
 err:
diff -r 99cc390f8e88 -r b485a0eb3db6 lib/libc/arch/vax/sys/sbrk.S
--- a/lib/libc/arch/vax/sys/sbrk.S      Thu Jul 18 12:21:52 2013 +0000
+++ b/lib/libc/arch/vax/sys/sbrk.S      Thu Jul 18 12:27:01 2013 +0000
@@ -31,12 +31,14 @@
 
 #if defined(SYSLIBC_SCCS) && !defined(lint)
        /* .asciz "@(#)sbrk.s   8.1 (Berkeley) 6/4/93" */
-RCSID("$NetBSD: sbrk.S,v 1.11 2011/01/25 02:38:15 matt Exp $")
+RCSID("$NetBSD: sbrk.S,v 1.12 2013/07/18 12:27:01 matt Exp $")
 #endif /* SYSLIBC_SCCS and not lint */
 
        .globl  _end
        .globl  _C_LABEL(__minbrk)
-       .globl  CURBRK
+       .globl  _C_LABEL(__curbrk)
+       .hidden _C_LABEL(__minbrk)
+       .hidden _C_LABEL(__curbrk)
 
 #ifdef WEAK_ALIAS
 WEAK_ALIAS(sbrk, _sbrk)
@@ -45,19 +47,20 @@
        .data
 _C_LABEL(__minbrk):
        .long   _end
-CURBRK:
+_C_LABEL(__curbrk):
        .long   _end
        .text
 
 ENTRY(_sbrk, 0)
-       addl3   CURBRK,4(%ap),-(%sp)
+       moval   _C_LABEL(__curbrk),%r5
+       addl3   (%r5),4(%ap),-(%sp)
        pushl   $1
        movl    %ap,%r3
        movl    %sp,%ap
        chmk    $ SYS_break
        jcs     err
-       movl    CURBRK,%r0
-       addl2   4(%r3),CURBRK
+       movl    (%r5),%r0
+       addl2   4(%r3),(%r5)
        ret
 err:
        jmp     CERROR+2



Home | Main Index | Thread Index | Old Index