<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src-test2/lib/libc/stdlib, branch release/7.1.0</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src-test2/atom?h=release%2F7.1.0</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src-test2/atom?h=release%2F7.1.0'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/'/>
<updated>2008-11-10T17:30:49Z</updated>
<entry>
<title>MFC:</title>
<updated>2008-11-10T17:30:49Z</updated>
<author>
<name>Jason Evans</name>
<email>jasone@FreeBSD.org</email>
</author>
<published>2008-11-10T17:30:49Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=d05be0bb64586f5742b8efeaf997ac51b1db87e1'/>
<id>urn:sha1:d05be0bb64586f5742b8efeaf997ac51b1db87e1</id>
<content type='text'>
	Revert to preferring mmap(2) over sbrk(2) when mapping memory, due
	to potential extreme contention in the kernel for multi-threaded
	applications on SMP systems.

Approved by:	re (kib)
</content>
</entry>
<entry>
<title>MFC r183565:</title>
<updated>2008-10-26T21:55:19Z</updated>
<author>
<name>Ed Schouten</name>
<email>ed@FreeBSD.org</email>
</author>
<published>2008-10-26T21:55:19Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=279ae1cd52703d9f703ae7152a92668c8f0d26e5'/>
<id>urn:sha1:279ae1cd52703d9f703ae7152a92668c8f0d26e5</id>
<content type='text'>
  Small cleanups to openpty().

  - Pass O_NOCTTY to posix_openpt(2). This makes the implementation work
    consistently on implementations that make the PTY the controlling TTY
    by default.

  - Call unlockpt() before opening the slave device. POSIX mentions that
    de slave device should only be opened after grantpt() and unlockpt()
    have been called.

  - Replace some redundant code by a label.

As a safety net, add a call to revoke() to unlockpt(). All applications
out there use openpty(), explicitly call revoke() or implement their own
PTY allocation routines. Adding the call to unlockpt() won't hurt, but
will prevent foot-shooting.

Reviewed by:	jhb, kib
Approved by:	re
</content>
</entry>
<entry>
<title>MFC allocator improvements and fixes:</title>
<updated>2008-08-16T20:14:21Z</updated>
<author>
<name>Jason Evans</name>
<email>jasone@FreeBSD.org</email>
</author>
<published>2008-08-16T20:14:21Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=b6a33e87c0af0760226537fabb64cf9ec5780bb8'/>
<id>urn:sha1:b6a33e87c0af0760226537fabb64cf9ec5780bb8</id>
<content type='text'>
* Enhance the chunk map to support run coalescing, and substantially reduce
  the number of red-black tree operations performed.

* Remove unused code.

* Fix arena_run_reg_dalloc() to use the entire precomputed division table.

* Improve lock preemption performance for hyperthreaded CPUs.
</content>
</entry>
<entry>
<title>MFC:  r181150, r181266</title>
<updated>2008-08-08T00:49:28Z</updated>
<author>
<name>Sean Farley</name>
<email>scf@FreeBSD.org</email>
</author>
<published>2008-08-08T00:49:28Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=a18bcf9339f93eebff55e2caa53f70a3800009f3'/>
<id>urn:sha1:a18bcf9339f93eebff55e2caa53f70a3800009f3</id>
<content type='text'>
Detect if the application has cleared the environ variable by setting
the first value (environ[0]) to NULL.  This is in addition to the
current detection of environ being replaced, which includes being set to
NULL.  Without this fix, the environment is not truly wiped, but appears
to be by getenv() until an *env() call is made to alter the enviroment.

This change is necessary to support those applications that use this
method for clearing environ such as Dovecot and Postfix.  Applications
such as Sendmail and the base system's env replace environ (already
detected).  While neither of these methods are defined by SUSv3, it is
best to support them due to historic reasons and in lieu of a clean,
defined method.

Add extra units tests for clearing environ using four different methods:
1. Set environ to NULL pointer.
2. Set environ[0] to NULL pointer.
3. Set environ to calloc()'d NULL-terminated array.
4. Set environ to static NULL-terminated array.

Noticed by:	Timo Sirainen
Reviewed by:	ache
</content>
</entry>
<entry>
<title>MFC r180323:</title>
<updated>2008-07-11T09:40:14Z</updated>
<author>
<name>Daniel Gerzo</name>
<email>danger@FreeBSD.org</email>
</author>
<published>2008-07-11T09:40:14Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=81380c4e8c0867631d2b1acd309d6456be72c483'/>
<id>urn:sha1:81380c4e8c0867631d2b1acd309d6456be72c483</id>
<content type='text'>
- remove superfluous word
- remove contractions
</content>
</entry>
<entry>
<title>MFC r180325 and r180329:</title>
<updated>2008-07-11T09:35:20Z</updated>
<author>
<name>Daniel Gerzo</name>
<email>danger@FreeBSD.org</email>
</author>
<published>2008-07-11T09:35:20Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=6276ba90fc0eb1cefbbf8609b3b2bb95eba93ce4'/>
<id>urn:sha1:6276ba90fc0eb1cefbbf8609b3b2bb95eba93ce4</id>
<content type='text'>
- This code was intially obtained from NetBSD, but it's missing licence
  statement. Add the one from the current NetBSD version.
- Add description about a missing return value [1]

PR:		docs/75995
Submitted by:	Tarc &lt;tarc@po.cs.msu.su&gt;
</content>
</entry>
<entry>
<title>MFC rev. 180024:</title>
<updated>2008-06-30T09:16:22Z</updated>
<author>
<name>Daniel Gerzo</name>
<email>danger@FreeBSD.org</email>
</author>
<published>2008-06-30T09:16:22Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=f56042975ab83942d158661311331634dd210afe'/>
<id>urn:sha1:f56042975ab83942d158661311331634dd210afe</id>
<content type='text'>
- Mark the section describing return values with an appropriate
  section flag.

PR:		docs/122818
</content>
</entry>
<entry>
<title>MFC allocator improvements and fixes:</title>
<updated>2008-06-16T23:42:05Z</updated>
<author>
<name>Jason Evans</name>
<email>jasone@FreeBSD.org</email>
</author>
<published>2008-06-16T23:42:05Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=bb6ada98aa046025d697f7fb7adc4b4e10df1b58'/>
<id>urn:sha1:bb6ada98aa046025d697f7fb7adc4b4e10df1b58</id>
<content type='text'>
* Implement more compact red-black trees, thus reducing memory usage
  by ~0.5-1%.

* Add a separate tree to track dirty-page-containing chunks, thus
  improving worst case allocation performance.

* Fix a deadlock in base_alloc() for the error (OOM) path.

* Catch integer overflow for huge allocations when using sbrk(2).

* Fix bit vector initialization for run headers.  This fix has no
  practical impact for correct programs.  Incorrect programs will
  potentially experience allocation failures rather than memory
  corruption, both of which are "undefined behavior".
</content>
</entry>
<entry>
<title>MFC: 1.16: Use calloc() instead of zeroing memory ourselves.</title>
<updated>2008-04-22T08:05:38Z</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@FreeBSD.org</email>
</author>
<published>2008-04-22T08:05:38Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=f1ee68865479a83dfb1f8099e7e973bad0484036'/>
<id>urn:sha1:f1ee68865479a83dfb1f8099e7e973bad0484036</id>
<content type='text'>
     1.17: Better strfmon(3) conversion specifiers sanity checking.
     1.18: Fix memory leaks.
</content>
</entry>
<entry>
<title>MFC: Merge malloc(3) improvements and fixes.  The highlights are:</title>
<updated>2008-03-07T22:39:39Z</updated>
<author>
<name>Jason Evans</name>
<email>jasone@FreeBSD.org</email>
</author>
<published>2008-03-07T22:39:39Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src-test2/commit/?id=d25eaea3901102b810ad0b75e3f464935b2b95ca'/>
<id>urn:sha1:d25eaea3901102b810ad0b75e3f464935b2b95ca</id>
<content type='text'>
* Avoid re-zeroing memory in calloc() when possible.

* Use pthread mutexes where possible instead of libc "spinlocks", and
  actually spin some during contention before blocking.

* Implement dynamic load balancing of thread--&gt;arena mapping.

* Avoid floating point math in order to avoid increased context switch
  overhead for applications that otherwise would not use floating point
  math.

* Restructure how sbrk() and mmap() are used to acquire memory mappings.
  This provides a way to force malloc to only use sbrk(), which can be
  useful in the context of resource limits.

* Reduce the number of mmap() calls typically necessary when allocating
  a chunk.

* Track dirty unused pages so that they can be purged if they exceed a
  threshold.

* Try to realloc() large objects in place.

* Manage page runs with trees instead of chunk maps, which allows
  logarithmic-time run allocation.
</content>
</entry>
</feed>
