yamt
b79fded28d
use mremap for huge -> huge realloc.
...
fix PR/31425 (Nicolas Joly) and possibly PR/36175 (Brian de Alwis).
2007-10-16 15:12:16 +00:00
yamt
89aa62f9b2
we don't have reallocf.
2007-10-15 11:18:44 +00:00
yamt
687cd24ebe
make lint happy.
2007-10-15 10:30:56 +00:00
yamt
1277f9b0a0
malloc_print_stats: print huge_allocated correctly. it's already in bytes.
2007-10-15 10:28:10 +00:00
yamt
14bfffc9db
use MAP_ALIGNED.
2007-10-15 00:05:00 +00:00
ad
3465d8db6f
Add defs for hppa. From he@.
2007-10-09 00:59:52 +00:00
he
7ed9cc8edd
On sparc64, both __sparc__ and __sparc64__ is defined. Avoid redefinition
...
of size constants for sparc64.
This code still produces many, many lint warnings due to "may loose accuracy"
when mixing long/int, and also warnings related to <<.
2007-10-07 21:45:18 +00:00
ad
81e619b9a4
Update for jemalloc.
2007-10-06 01:09:48 +00:00
ad
9b64888c5d
Use jemalloc as the default allocator unless USE_JEMALLOC=no.
2007-10-06 01:09:07 +00:00
ad
e7a9e46b7e
Port to NetBSD. Note: posix_memalign() is here, but it's not exported
...
via the headers yet.
2007-10-05 23:42:23 +00:00
ad
8a475bcba1
Pull in jemalloc from FreeBSD:
...
FreeBSD: src/lib/libc/stdlib/malloc.c,v 1.147 2007/06/15 22:00:16 jasone Exp
2007-10-05 23:39:58 +00:00
kristerw
3a6ef3e3c1
Keep track of atexit functions that are added while processing
...
atexit functions, to ensure that the new functions will be called.
2007-08-08 01:05:34 +00:00
kristerw
af220472c9
Ensure that the struct atexit_handler has been removed from the list
...
of pending atexit handlers before the structure is reused. This prevents
__cxa_finalize from going into an infinite loop when an atexit handler
register a new atexit handler as in:
#include <stdlib.h>
void two(void) {
}
void one(void) {
atexit(two);
}
int main(void) {
atexit(one);
return 0;
}
2007-08-08 00:51:18 +00:00
wiz
e3d3393d01
Add xref to shquote(3), suggested by joerg. Bump date.
2007-08-02 23:45:10 +00:00
ginsbach
15b661abe9
Fix several end cases:
...
o If a long option looks like an ambiguous abbreviation of two or more long
options, but all the possible interpretations would return the same
value, then just return that value without complaining that it's
ambiguous.
o If a long option could be interpreted either as an exact match for one
long option, or as an abbreviation for one or more other long options,
then treat it as the exact match.
These changes align NetBSD's getopt_long(3) with the current behavior of
GNU getopt_long(3), the de facto standard, and FreeBSD's getopt_long(3).
2007-07-05 16:05:40 +00:00
ginsbach
a3ae2738c9
Document that getopt_long(3) can and will accept unique abbreviated long
...
option names. This feature has been present since getopt_long(3) was first
released in NetBSD 1.5. This is also standard GNU getopt_long(3) behavior.
2007-07-02 17:56:17 +00:00
lukem
2d50a59010
Use IEC 60027-2 prefixes for 2^n based prefixes.
2007-04-12 06:50:39 +00:00
christos
cdcb070b9c
remove bogus (void)&var; From Anon Ymous
2006-12-18 00:40:14 +00:00
elad
8e60b8367c
PR/34984: Denis Lagno: minor problems with tsearch.3
2006-11-26 13:10:54 +00:00
christos
3d98aa3f4b
fix spelling of accidentally; from Zapher
2006-11-24 19:37:02 +00:00
elad
25c47f2333
PR/34602: sushant: Bug in malloc implementation contains dead code in
...
free_pages()
Applied patch from Mindaugas <unex at linija org> (in #NetBSD-code), thanks
2006-10-08 16:25:15 +00:00
thorpej
82fd1ebbaa
- Move strtoll.c and strtoull.c from libc/stdlib to common/libc/stdlib.
...
- Add strtoll.c and strtoull.c to libkern.
2006-10-08 03:14:55 +00:00
elad
a35b07a2ca
Correctly recover signal state if failed trying to set it.
...
Patch from David A. Holland in #NetBSD-code, thanks!
2006-10-07 22:16:19 +00:00
wiz
ec15e07b4a
Switch from 4-clause to 2-clause BSD license.
...
Ok dillo@, board@.
2006-10-04 17:29:42 +00:00
mjl
d072c175eb
s,floride,fluoride,
2006-06-28 06:25:15 +00:00
wiz
20862d8c44
Bump date for previous.
2006-04-24 21:54:37 +00:00
liamjfoy
14a07a0706
- add a missing ;
...
- use 'size' instead of 'nsize', makes more sense
ok christos@
2006-04-24 20:46:23 +00:00
thorpej
7d3d66c90e
Move strtoumax.c from libc/stdlib to common/libc/stdlib and include it
...
in libkern. Required for new code coming soon.
2006-04-22 15:33:33 +00:00
drochner
273bf6508d
correct multiplicand in pseudorandom generation
2006-03-31 11:43:54 +00:00
drochner
04293de9bb
switch byteorder of seed to match previous (and documented) behaviour
2006-03-31 11:42:31 +00:00
kleink
c66ffccfbe
Xref rnd(4).
2006-03-24 16:14:42 +00:00
drochner
f81322cf18
build erand48_ieee754.c on everything but vax
2006-03-22 22:03:58 +00:00
drochner
7a2af2aba0
Rewrite erand48() to put the random bits into the mantissa by simple
...
bitshifts instead of calling ldexp() three times.
(for ieee doubles only -- vax can't use it, so the old version
needs to stay around)
This removes the dependency on ldexp() which also didn't participate in
the usual __RENAME game, thus lead to confusion.
In addition, this version is almost 3 times as fast for me.
2006-03-22 21:06:03 +00:00
drochner
e89a43e9fd
<math.h> is just needed for the ldexp() call in erand48() -
...
remove unnecessary dependency
2006-03-22 20:52:16 +00:00
christos
3040914cf6
Coverity CID 1560: Don't leak memory when multiple currency symbols are present
2006-03-19 01:50:49 +00:00
christos
7ac9949871
Coverity CID 2528: Don't delete the node we are about to return.
2006-03-19 01:12:08 +00:00
wiz
929e506267
Use more macros.
2006-03-15 20:08:24 +00:00
kleink
bc89c06cbf
Add strtof(3) and strtold(3); welcome libc 12.137.
2006-03-15 17:35:17 +00:00
wiz
5d1e8b2745
Fix some typos.
2006-02-25 02:28:55 +00:00
kleink
3cd8501c1e
Drop in gdtoa as a replacement for dtoa, strtod() from stdlib/strtod.c.
2006-01-25 15:43:01 +00:00
christos
6eaa70365b
Kill _Exit; breaks build on cygwin and this implementation "is not exactly
...
equivalent to calling _exit".
2006-01-20 22:02:07 +00:00
perry
46359204cf
__inline__ -> inline
2005-12-24 21:42:02 +00:00
perry
4e11af46bc
Remove leading __ from __(const|inline|signed|volatile) -- it is obsolete.
2005-12-24 21:11:15 +00:00
christos
e5548b402a
Use reach-over sources from common/lib/libc
2005-12-20 19:31:47 +00:00
christos
bea4991aaa
Older gcc does not support #ifdef inside macro expansion.
2005-12-04 17:57:25 +00:00
yamt
e301b762a1
redo the previous; constify rather than making a string writable.
2005-12-02 14:19:43 +00:00
yamt
a6a060b04b
note that "argv" is not really const.
2005-12-02 14:11:01 +00:00
yamt
9de32b7fa1
don't make internal functions pretend to take a const argument.
2005-12-02 14:08:51 +00:00
christos
03256c6e55
WARNS=4
2005-11-29 03:11:58 +00:00
wiz
72a37764e0
Punctuation nits; grammar fix.
2005-09-26 10:54:46 +00:00