_REENT_CHECK_VERIFY calls __assert_func even if NDEBUG is defined

Keith Packard keithp@keithp.com
Tue Apr 28 22:00:15 GMT 2020


"R. Diez via Newlib" <newlib@sourceware.org> writes:

> Note that sizeof( struct _reent  ) increases from 240 bytes to 1064
> bytes (tested with Newlib version 3.3.0).

If you're tight on RAM, you might look at the newlib fork, picolibc,
which uses native TLS support for reentrant data values like
_rand_next. With that approach, your thread-local storage contains only
values used by your application and malloc need never be called. In this
case, the per-thread data would be only eight bytes.

-- 
-keith
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/newlib/attachments/20200428/629ec956/attachment.sig>


More information about the Newlib mailing list