<feed xmlns='http://www.w3.org/2005/Atom'>
<title>uClibc-alpine/libc/stdlib/malloc, branch 0.9.32</title>
<subtitle>Where we track our uclibc patches
</subtitle>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/'/>
<entry>
<title>Fix malloc alignment</title>
<updated>2011-04-11T11:26:56+00:00</updated>
<author>
<name>Bernd Schmidt</name>
<email>bernds@codesourcery.com</email>
</author>
<published>2011-04-11T11:19:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=eff2d0ba5890b517ef5bc9d0269d6149556c12c8'/>
<id>eff2d0ba5890b517ef5bc9d0269d6149556c12c8</id>
<content type='text'>
In commit 3e0a1f388, Richard tried to fix malloc alignments by using
 alignof (double __attribute_aligned__(sizeof (size_t))).
This doesn't work, since attribute_aligned overrides the alignment
rather than providing a minimum. On C6X, malloc returns four-byte
aligned values rather than the necessary eight-byte alignment.

It's simpler to use a comparison and pick the bigger of the two values,
so that's what I've done.

Signed-off-by: Bernd Schmidt &lt;bernds@codesourcery.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In commit 3e0a1f388, Richard tried to fix malloc alignments by using
 alignof (double __attribute_aligned__(sizeof (size_t))).
This doesn't work, since attribute_aligned overrides the alignment
rather than providing a minimum. On C6X, malloc returns four-byte
aligned values rather than the necessary eight-byte alignment.

It's simpler to use a comparison and pick the bigger of the two values,
so that's what I've done.

Signed-off-by: Bernd Schmidt &lt;bernds@codesourcery.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>memalign: include sys/param.h for MAX</title>
<updated>2011-03-16T19:10:26+00:00</updated>
<author>
<name>Bernhard Reutner-Fischer</name>
<email>rep.dot.nop@gmail.com</email>
</author>
<published>2011-03-16T19:09:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=2f9445814cb01b460a1426d41e05c738a4a37f86'/>
<id>2f9445814cb01b460a1426d41e05c738a4a37f86</id>
<content type='text'>
libc/stdlib/malloc/memalign.c:22:1: warning: "MAX" redefined In file included from
./libpthread/nptl/sysdeps/unix/sysv/linux/i386/lowlevellock.h:25,
                 from ./include/bits/libc-lock.h:36,
                 from ./include/bits/stdio-lock.h:23,
                 from ./include/bits/uClibc_mutex.h:71,
                 from libc/stdlib/malloc/malloc.h:135,
                 from libc/stdlib/malloc/memalign.c:18:
./include/sys/param.h:75:1: warning: this is the location of the previous definition

Signed-off-by: Bernhard Reutner-Fischer &lt;rep.dot.nop@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
libc/stdlib/malloc/memalign.c:22:1: warning: "MAX" redefined In file included from
./libpthread/nptl/sysdeps/unix/sysv/linux/i386/lowlevellock.h:25,
                 from ./include/bits/libc-lock.h:36,
                 from ./include/bits/stdio-lock.h:23,
                 from ./include/bits/uClibc_mutex.h:71,
                 from libc/stdlib/malloc/malloc.h:135,
                 from libc/stdlib/malloc/memalign.c:18:
./include/sys/param.h:75:1: warning: this is the location of the previous definition

Signed-off-by: Bernhard Reutner-Fischer &lt;rep.dot.nop@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nptl: fix malloc library locking</title>
<updated>2010-04-22T15:45:25+00:00</updated>
<author>
<name>Timo Teräs</name>
<email>timo.teras@iki.fi</email>
</author>
<published>2010-04-22T05:41:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=744842bf666f31cfdd355598c244cef2487eded4'/>
<id>744842bf666f31cfdd355598c244cef2487eded4</id>
<content type='text'>
Update malloc library to use internal uclibc locking primitives
to get the libpthread calls correct.

Signed-off-by: Timo Teräs &lt;timo.teras@iki.fi&gt;
Signed-off-by: Austin Foxley &lt;austinf@cetoncorp.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Update malloc library to use internal uclibc locking primitives
to get the libpthread calls correct.

Signed-off-by: Timo Teräs &lt;timo.teras@iki.fi&gt;
Signed-off-by: Austin Foxley &lt;austinf@cetoncorp.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>prettify make clean</title>
<updated>2010-03-25T14:39:02+00:00</updated>
<author>
<name>Bernhard Reutner-Fischer</name>
<email>rep.dot.nop@gmail.com</email>
</author>
<published>2010-03-25T14:17:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=abdbaa897b3d7b5b72c8521a38aa84cada242837'/>
<id>abdbaa897b3d7b5b72c8521a38aa84cada242837</id>
<content type='text'>
Signed-off-by: Bernhard Reutner-Fischer &lt;rep.dot.nop@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Bernhard Reutner-Fischer &lt;rep.dot.nop@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>malloc: fix race condition and other bugs in the no-mmu malloc</title>
<updated>2009-12-19T21:53:32+00:00</updated>
<author>
<name>Freeman Wang</name>
<email>xwang@ubicom.com</email>
</author>
<published>2009-12-19T21:43:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=23528282b771d1af3df0fa17f1e909ad3b663f59'/>
<id>23528282b771d1af3df0fa17f1e909ad3b663f59</id>
<content type='text'>
Fixes multiple race conditions on mmb list. This was done by
making the mmb_heap_lock into a recursive lock and making the
regular heap_lock extend to cover the mmb heap handling.

Also move the new_mmb allocation up to before the mmb list is
iterated through to find the insertion point. When the mmb_heap
also runs out and needs to be extended when the regular heap is
just extended, the mmb list could be messed up.

Signed-off-by: Freeman Wang &lt;xwang@ubicom.com&gt;
Signed-off-by: Austin Foxley &lt;austinf@cetoncorp.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes multiple race conditions on mmb list. This was done by
making the mmb_heap_lock into a recursive lock and making the
regular heap_lock extend to cover the mmb heap handling.

Also move the new_mmb allocation up to before the mmb list is
iterated through to find the insertion point. When the mmb_heap
also runs out and needs to be extended when the regular heap is
just extended, the mmb list could be messed up.

Signed-off-by: Freeman Wang &lt;xwang@ubicom.com&gt;
Signed-off-by: Austin Foxley &lt;austinf@cetoncorp.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>nommu: use MAP_UNINITIALIZE for mallocs</title>
<updated>2009-11-24T02:35:34+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@gentoo.org</email>
</author>
<published>2009-11-24T02:35:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=00673f93826bf1fbde728d202c319a684bb87150'/>
<id>00673f93826bf1fbde728d202c319a684bb87150</id>
<content type='text'>
Now that the kernel supports MAP_UNINITIALIZE, have the malloc places use
it to get real uninitialized memory on no-mmu systems.  This avoids a lot
of normally useless overhead involved in zeroing out all of the memory
(sometimes multiple times).

Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Now that the kernel supports MAP_UNINITIALIZE, have the malloc places use
it to get real uninitialized memory on no-mmu systems.  This avoids a lot
of normally useless overhead involved in zeroing out all of the memory
(sometimes multiple times).

Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>malloc: handle size overflows in realloc()</title>
<updated>2009-10-15T23:47:12+00:00</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier@gentoo.org</email>
</author>
<published>2009-10-15T23:47:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=07e0ce9fa7f428720bee9decb5d0bb368108d93f'/>
<id>07e0ce9fa7f428720bee9decb5d0bb368108d93f</id>
<content type='text'>
The malloc() code checks the incoming size to make sure the header
adjustment doesn't cause overflow in the size storage.  Add the same
check to realloc() to catch stupid stuff like realloc(..., -1).

Reported-by: James Coleman &lt;james.coleman@ubicom.com&gt;
Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The malloc() code checks the incoming size to make sure the header
adjustment doesn't cause overflow in the size storage.  Add the same
check to realloc() to catch stupid stuff like realloc(..., -1).

Reported-by: James Coleman &lt;james.coleman@ubicom.com&gt;
Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>trim Experimentally off and uncommented hidden</title>
<updated>2009-09-18T18:57:40+00:00</updated>
<author>
<name>Bernhard Reutner-Fischer</name>
<email>rep.dot.nop@gmail.com</email>
</author>
<published>2009-09-18T18:57:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=21730caa6647f645974e132ca8afec79b4eeab2b'/>
<id>21730caa6647f645974e132ca8afec79b4eeab2b</id>
<content type='text'>
  sed -i -e '/Experimentally off - /d' $(grep -rl "Experimentally off - " *)
  sed -i -e '/^\/\*[[:space:]]*libc_hidden_proto(/d' $(grep -rl "libc_hidden_proto" *)
  should be a nop

Signed-off-by: Bernhard Reutner-Fischer &lt;rep.dot.nop@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
  sed -i -e '/Experimentally off - /d' $(grep -rl "Experimentally off - " *)
  sed -i -e '/^\/\*[[:space:]]*libc_hidden_proto(/d' $(grep -rl "libc_hidden_proto" *)
  should be a nop

Signed-off-by: Bernhard Reutner-Fischer &lt;rep.dot.nop@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>support building out-of-tree</title>
<updated>2009-08-17T17:17:00+00:00</updated>
<author>
<name>Bernhard Reutner-Fischer</name>
<email>rep.dot.nop@gmail.com</email>
</author>
<published>2009-08-17T17:17:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=49d8a0e9c6e32701c7eca91a1204237d3a334e38'/>
<id>49d8a0e9c6e32701c7eca91a1204237d3a334e38</id>
<content type='text'>
  Handle O=

Signed-off-by: Bernhard Reutner-Fischer &lt;rep.dot.nop@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
  Handle O=

Signed-off-by: Bernhard Reutner-Fischer &lt;rep.dot.nop@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>- revert 24148:24151</title>
<updated>2008-11-26T08:41:09+00:00</updated>
<author>
<name>Bernhard Reutner-Fischer</name>
<email>rep.dot.nop@gmail.com</email>
</author>
<published>2008-11-26T08:41:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git-old.alpinelinux.org/uClibc-alpine/commit/?id=20cff295659e9bd1bee2c316ee17a53cad693ea2'/>
<id>20cff295659e9bd1bee2c316ee17a53cad693ea2</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
