Skip to content

Commit

Permalink
clib: optimize CRTL
Browse files Browse the repository at this point in the history
use alias for _heapmin class of functions
_bheapmin equal _bheapshrink
_heapmin equal _heapshrink
_nheapmin equal _nheapshrink
_fheapmin equal _fheapshrink
  • Loading branch information
jmalak committed Jul 12, 2024
1 parent 79924b5 commit e053ba9
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 27 deletions.
4 changes: 4 additions & 0 deletions bld/clib/alias/gen/aliases.dat
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,10 @@ getpid getpid _getpid d16 d32 nt nta ntm ntp
getpwe setpwent endpwent l32 lpc lmp
getws_ getws _getws d16 d32 nt nta ntm ntp o16 o32 q16 q32 w16 w32 l32
gmtm_r _gmtime gmtime_r l32 lpc lmp
heapmi _heapshrink _heapmin d16 d32 nt nta ntm ntp o16 o32 q16 q32 w16 w32 l32 lpc lmp rdu
bheapm _bheapshrink _bheapmin d16 o16 q16 w16
fheapm _fheapshrink _fheapmin d16 o16 q16 w16
nheapm _nheapshrink _nheapmin d16 d32 nt nta ntm ntp o16 o32 q16 q32 w16 w32 l32 lpc lmp rdu
i64toa lltoa _i64toa d16 d32 nt nta ntm ntp nvc nvl o16 o32 q16 q32 w16 w32 l32 lpc lmp rdu rdk
index_ strchr index d16 d32 nt nta ntm ntp nvc nvl o16 o32 q16 q32 w16 w32 l32 lpc lmp rdu rdk
isatty isatty _isatty d16 d32 nt nta ntm ntp o16 o32 w16 w32 rdu rdk
Expand Down
7 changes: 1 addition & 6 deletions bld/clib/heap/c/bheapmin.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
*
* Open Watcom Project
*
* Copyright (c) 2024 The Open Watcom Contributors. All Rights Reserved.
* Copyright (c) 2024-2024 The Open Watcom Contributors. All Rights Reserved.
* Portions Copyright (c) 1983-2002 Sybase, Inc. All Rights Reserved.
*
* ========================================================================
Expand Down Expand Up @@ -37,11 +37,6 @@
#include "heap.h"


_WCRTLINK int _bheapmin( __segment seg )
{
return( _bheapshrink( seg ) );
}

_WCRTLINK int _bheapshrink( __segment seg )
{
if( seg == _DGroup() )
Expand Down
11 changes: 1 addition & 10 deletions bld/clib/heap/c/fheapmin.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
*
* Open Watcom Project
*
* Copyright (c) 2024 The Open Watcom Contributors. All Rights Reserved.
* Portions Copyright (c) 1983-2002 Sybase, Inc. All Rights Reserved.
*
* ========================================================================
Expand Down Expand Up @@ -46,18 +47,8 @@ _WCRTLINK int _heapshrink( void )
return( _fheapshrink() );
}

_WCRTLINK int _heapmin( void )
{
return( _fheapshrink() );
}

#endif

_WCRTLINK int _fheapmin( void )
{
return( _fheapshrink() );
}

_WCRTLINK int _fheapshrink( void )
{
__segment seg;
Expand Down
12 changes: 1 addition & 11 deletions bld/clib/heap/c/nheapmin.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
*
* Open Watcom Project
*
* Copyright (c) 2002-2022 The Open Watcom Contributors. All Rights Reserved.
* Copyright (c) 2002-2024 The Open Watcom Contributors. All Rights Reserved.
* Portions Copyright (c) 1983-2002 Sybase, Inc. All Rights Reserved.
*
* ========================================================================
Expand Down Expand Up @@ -64,18 +64,8 @@ _WCRTLINK int _heapshrink( void )
return( _nheapshrink() );
}

_WCRTLINK int _heapmin( void )
{
return( _nheapshrink() );
}

#endif

_WCRTLINK int _nheapmin( void )
{
return( _nheapshrink() );
}

#if defined(__OS2__) && !defined(_M_I86) || defined(__WINDOWS__) || defined(__NT__) || \
defined(__CALL21__) || defined(__RDOS__) || defined(__DOS_EXT__)

Expand Down

0 comments on commit e053ba9

Please sign in to comment.