summaryrefslogtreecommitdiffstats
path: root/lib/libc
Commit message (Collapse)AuthorAgeFilesLines
* Add malloc_usable_size(3).jasone2006-03-284-3/+47
| | | | Discussed with: arch@
* Add semaphore functions, and remove some dupes from the #if 0 section.des2006-03-282-4/+20
|
* Add a bunch of missing pthread functions, and move out-of-order functions.des2006-03-282-13/+128
|
* If the query choked with EDNS0, retry without EDNS0.ume2006-03-281-8/+24
| | | | Obtained from: res_nquery() of BIND9.
* Allocate space for thread pointer, this allows thread library to accessdavidxu2006-03-281-3/+3
| | | | its pointer from begin, and simplifies _get_curthread() in libthr.
* Allow the 'n' option to decrease the number of arenas below the default,jasone2006-03-261-2/+16
| | | | | to as little as one arena. Also, limit the number of arenas to avoid a potential invariant violation in base_alloc().
* Add comments and reformat/rearrange code. There are no significantjasone2006-03-261-208/+224
| | | | functional changes in this commit.
* - Use ANSI C prototype.ume2006-03-253-152/+59
| | | | - Remove trailing space.
* Convert TINY_MIN_2POW from a cpp macro to tiny_min_2pow (a variable), andjasone2006-03-241-21/+37
| | | | | | | | | | | | | | | determine its value at run time according to other relevant values. This avoids the creation of runs that are incompletely utilized, as long as pagesize isn't too large (>32kB, given the current RUN_MIN_REGS_2POW setting). Increase the size of several structure bitfields in arena_run_t in order to avoid integer overflow in the case that a run's header does not overlap with the space that is usable as application allocation regions. Given the tiny_min_2pow change, this fix has no additional impact unless pagesize is >32kB. Reported by: kris
* When res_nquerydomain() returns SERVFAIL, we should try next domain.ume2006-03-242-5/+26
|
* When res_send() fails, we should reserve an error code.ume2006-03-241-2/+2
|
* Add USE_BRK-specific code in malloc_init_hard() to allow the firstjasone2006-03-241-65/+110
| | | | | | | | | | | | | | | | | | | internally used chunk to start at the beginning of the heap, rather than at a chunk-aligned address. This reduces mapped memory somewhat for 32-bit architectures. Add the arena_run_link_t type and use it wherever a run object is only used as a ring 'header'. This saves approximately 40 kB of memory per arena. Remove an obsolete (no longer used) code path from base_alloc(), which supported the internal allocation of objects larger than the chunk size. Enhance chunk_dealloc() to cache chunk addresses for all deallocated chunks. This has no impact for most programs, but has the potential to reduce VM map fragmentation for programs that use huge allocations.
* Document that the documented 2GB mmap limit is actually apeter2006-03-231-22/+8
| | | | | | | | documentation bug. We switched to page indexes some time around FreeBSD 2.2. The actual 'len' limit is the maximum file size or what will fit in your address space, whichever comes first. It should be possible to make 1TB files on 32 bit systems, but of course address space runs out long before then.
* It's not enough to provide symbol map files; you also have to add themdes2006-03-233-0/+6
| | | | | | to ${SYM_MAPS}. This unbreaks world with SYMVER_ENABLED. Pointy hat to: ume
* We have gmtime_r(3).ume2006-03-211-0/+1
|
* Update the resolver in libc to BIND9's one.ume2006-03-2142-7838/+369
| | | | | | | | | | | | | | | | | | | | | | Since, res_sendsigned(3) and the friends use MD5 functions, it is hard to include them without having MD5 functions in libc. So, res_sendsigned(3) is not merged into libc. Since, res_update(3) in BIND9 is not binary compatible with our res_update(3), res_update(3) is leaved as is, except some necessary modifications. The res_update(3) and the friends are not essential part of the resolver. They are not defined in resolv.h but defined in res_update.h separately in BIND9. Further, they are not called from our tree. So, I hide them from our resolv.h, but leave them only for binary backward compatibility (perhaps, no one calls them). Since, struct __res_state_ext is not exposed in BIND9, I hide it from our resolv.h. And, global variable _res_ext is removed. It breaks binary backward compatibility. But, since it is not used from outside of our libc, I think it is safe. Reviewed by: arch@ (no objection)
* - Merge our local changes.ume2006-03-2138-123/+901
| | | | - Exclude unnecessary functions for us.
* This commit was generated by cvs2svn to compensate for changes in r156954,ume2006-03-211-47/+0
| | | | which included commits to RCS files with non-trunk default branches.
* This commit was generated by cvs2svn to compensate for changes in r156952,ume2006-03-2137-0/+10873
|\ | | | | | | which included commits to RCS files with non-trunk default branches.
| * Vendor import of BIND 9.3.2ume2006-03-2137-0/+10873
|
* When we are doing initialization against q, use its own size, notdelphij2006-03-211-1/+1
| | | | | | | the size of q2. This should be a no-op because q and q2 are of the same type. Submitted by: Alexey Dobriyan <adobriyan gmail com>
* Separate completely full runs from runs that are merely almost full, sojasone2006-03-201-61/+71
| | | | | | | that no linear searching is necessary if we resort to allocating from a run that is known to be mostly full. There are pathological edge cases that could have caused severely degraded performance, and this change fixes that.
* Optimize realloc() to reallocate in place if the old and new sizes arejasone2006-03-191-105/+167
| | | | | | | | | | | close enough to each other that reallocation would allocate a new region of the same size. This improves the performance of repeated incremental reallocations by up to three orders of magnitude. [1] Fix arena_new() to properly constrain run size if a small chunk size was specified during runtime configuration. Suggested by: se [1]
* Provide alternate default for SHLIBDIR before bsd.own.mk does this.ru2006-03-181-1/+2
| | | | Reported by: phk
* Reimplementation of world/kernel build options. For details, see:ru2006-03-172-5/+7
| | | | | | | | http://lists.freebsd.org/pipermail/freebsd-current/2006-March/061725.html The src.conf(5) manpage is to follow in a few days. Brought to you by: imp, jhb, kris, phk, ru (all bugs are mine)
* Modify allocation policy, in order to avoid excessive fragmentation forjasone2006-03-172-2503/+1070
| | | | | | | | | | | | | | | allocation patterns that involve a relatively even mixture of many different size classes. Reduce the chunk size from 16 MB to 2 MB. Since chunks are now carved up using an address-ordered first best fit policy, VM map fragmentation is much less likely, which makes smaller chunks not as much of a risk. This reduces the virtual memory size of most applications. Remove redzones, since program buffer overruns are no longer as likely to corrupt malloc data structures. Remove the C MALLOC_OPTIONS flag, and add H and S.
* Allow bsd.lib.mk to generate the symbol version map.deischen2006-03-161-14/+6
|
* Fix comment.ru2006-03-161-1/+1
|
* Desupport the undocumented NO_QUAD option, just don't compileru2006-03-165-21/+4
| | | | the quad support on 64-bit platforms.
* Add a non-optional newline after ".Bx".ru2006-03-151-1/+2
|
* Revert previous changes as we do support the .Ox macro for OpenBSD.andre2006-03-151-2/+4
| | | | Pointed out by: ceri, ru, delphij
* POSIXed strtoll() (and ours one too) can set errno to EINVAL, so checkache2006-03-141-1/+1
| | | | | | it first. Approved by: andre
* Fix HISTORY and point to OpenBSD.andre2006-03-141-5/+2
|
* Import of OpenBSD's strtonum(3) which is a nicer version of strtoll(3)andre2006-03-144-3/+227
| | | | | | | | providing proper error checking and other improvements. Obtained from: OpenBSD Requested by: flz (to port Open[BGP|OSPF]D) MFC after: 3 days
* ns_name_skip was recently redefined to __ns_name_skipdeischen2006-03-131-1/+1
| | | | | | like the others in <include/arpa/nameser.h>. Submitted by: ume
* Make _spinunlock() point to the spinunlock stub, not thedeischen2006-03-131-1/+1
| | | | spinlock stub.
* Add each directory's symbol map file to SYM_MAPS.deischen2006-03-1328-1/+48
|
* Add hooks to build libc with symbol versioning. This isdeischen2006-03-131-0/+14
| | | | | | | | disabled by default; add SYMVER_ENABLED=true to /etc/make.conf to enable it. libc should get a version bump before this is enabled by default. Reviewed by: davidxu
* Add symbol maps and initial symbol version definitions to libc.deischen2006-03-1329-0/+3241
| | | | Reviewed by: davidxu
* Add entries for new pthread stubs.davidxu2006-03-101-0/+30
|
* Remove mq.c, the POSIX mqueue is implemented in librt.davidxu2006-03-081-73/+0
| | | | Suggested by: deischen
* Add some more pthread stubs so that librt can use them.deischen2006-03-053-31/+168
| | | | | | | The thread jump table has been resorted, so you need to keep libc, libpthread, and libthr in sync. Submitted by: xu
* Remove a useless word.brueffer2006-03-051-1/+1
| | | | | | PR: 94087 Submitted by: Tadaaki Nagao <nagao@iij.ad.jp> MFC after: 3 days
* Sync with actual code.jcamou2006-03-031-2/+6
| | | | | | | | PR: docs/87681 Noticed by: Andreas Kohn <andreas@syndrom23.de> Reviewed by: brooks Approved by: trhodes (mentor) MFC after: 3 days
* Fix the %Q printf extension to behave as expectedphk2006-03-021-19/+9
|
* Handle the errors returned by res_querydomain() in same manner.ume2006-03-012-0/+40
| | | | | | Reported by: yar Tested by: yar, Rostislav Krasny <rosti.bsd__at__gmail.com> MFC after: 1 week
* Disconnect mqueue from buildworld, as I will implement it in seperateddavidxu2006-03-011-1/+1
| | | | library.
* Const'ify arguments to a couple of functions to fix breakagedeischen2006-02-281-2/+2
| | | | with -O2.
* Don't do a time travel to 12006...delphij2006-02-281-1/+1
|
* Staticize a couple of functions.deischen2006-02-2723-71/+106
| | | | | | Remove a few unused locks. Remove locks from application namespace.
OpenPOWER on IntegriCloud