summaryrefslogtreecommitdiff
path: root/lib/libc/stdlib/malloc.c
AgeCommit message (Collapse)Author
2000-07-06avoid losing precision warningschristos
2000-05-20Disable malloc's hints to the kernel - now that the madvise() syscallsimonb
actually does something, this can be expensive. From discussion on current-users. Note that the man page is already correct - we imported malloc.c from FreeBSD before they made the same change but malloc.3 after...
2000-04-07Fix the bug introduced in rev 1.28 and actually caused failure on alpha;enami
In the function malloc_make_chunks, don't define the local variable ``l'', which is used to hold the actual size of pginfo, as size_t. Define it as a signed integer as before. We expect it to become zero or negative value, and we know that it is much smaller than pagesize and it is small enough to fit in signed interger.
2000-04-07Backout the previous backing out.enami
2000-01-31Back out the previous 2 revs. The delint'ing of this file causedthorpej
something to break horribly on the Alpha.
2000-01-23Delint.mycroft
2000-01-23Partially delint, and a few microoptimizations.mycroft
1999-09-10Restore the behaviour of not setting errno to ENOMEM when allocating 0kleink
units of storage and returning a null pointer in System V mode; this was broken by the `fix' in rev. 1.24. Also, as it is stated in ISO C that such operation does not constitute an allocation failure, do not abort() even if the `X' option is set. Amusingly enough the SVID, Fourth Edition, specifies the `unique pointer' return behaviour for this kind of allocation, so this is kind of mis-named.
1999-08-22Need "namespace.h".kleink
1999-07-08Make sure errno is set to ENOMEM if we return NULL.thorpej
1999-07-05index -> ldx (and similar in some related variable names). Avoids a lintthorpej
warning.
1999-07-05Oops, back out 1.21. Christos and I apparently stepped on each other.thorpej
1999-07-05s/index/idx/christos
s/EXTRA_SANITY/MALLOC_EXTRA_SANITY/ const poisoning use sysconf to get the pagesize
1999-07-05Compute page size related parameters at run-time.thorpej
1999-07-05EXTRA_SANITY -> MALLOC_EXTRA_SANITY, consistently.thorpej
1999-07-04Only define MADV_FREE do MADV_DONTNEED if it's not already definedthorpej
by <sys/mman.h>.
1999-06-26The 'new malloc' (phk's malloc, from FreeBSD) is now our only malloc.tls
1999-01-29Protect access of state with a mutex. Miscellaneous notes:kleink
* still needs an implementation-independent ("reentrant.h") method for disabling cancellation, * break a leg to leave realloc() `storage compaction' as was for non-reentrant code, * use of stdio in assertion code is unsafe.
1998-11-15delintchristos
1998-08-26make memcpy into memmove in some casesperry
1998-08-10bzero->memset, bcopy->memcpy, bcmp->memcmpperry
1998-02-03remove obsolete register declarationsperry
1998-01-30update to lite-2perry
1997-07-21If port provides __weak_alias(), provide an Standard C and POSIX purejtc
identifier namespace by renaming non standard functions and variables such that they have a leading underscore. The library will use those names internally. Weak aliases are used to provide the original names to the API. This is only the first part of this change. It is most of the functions which are implemented in C for all NetBSD ports. Subsequent changes are to add the same support to the remaining C files, to assembly files, and to the automagically generated assembly source used for system calls. When all of the above is done, ports with weak alias support should add a definition for __weak_alias to <sys/cdefs.h>.
1997-07-13Add local.h for local prototypes.christos
Fix namespace issues for strtoq and strtouq Fix gcc warnings. Fix RCSID's
1997-04-07PR/3448: Bill Sommerfeld: Change "p" to __STRING(p)christos
1996-12-20don't confuse long and int; pointed out by lintcgd
1996-01-17The C standard says (about realloc) that "If size is zero and ptr isjtc
not a null pointer, the object it points to is freed." Reported by Peter Seebach in PR #1806.
1995-12-28New-style RCS ids.thorpej
1994-10-19 casting types.cgd
1993-08-26Declare rcsid strings so they are stored in text segment.jtc
1993-08-01Add RCS identifiers.mycroft
1993-03-21initial import of 386bsd-0.1 sourcescgd