<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glibc/string/Versions, branch master</title>
<subtitle>Fork of glibc for development</subtitle>
<id>https://git.zx2c4.com/glibc/atom/string/Versions?h=master</id>
<link rel='self' href='https://git.zx2c4.com/glibc/atom/string/Versions?h=master'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/'/>
<updated>2023-06-14T16:10:08Z</updated>
<entry>
<title>Implement strlcpy and strlcat [BZ #178]</title>
<updated>2023-06-14T16:10:08Z</updated>
<author>
<name>Florian Weimer</name>
<email>fweimer@redhat.com</email>
</author>
<published>2023-06-14T16:10:08Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=454a20c8756c9c1d55419153255fc7692b3d2199'/>
<id>urn:sha1:454a20c8756c9c1d55419153255fc7692b3d2199</id>
<content type='text'>
These functions are about to be added to POSIX, under Austin Group
issue 986.

The fortified strlcat implementation does not raise SIGABRT if the
destination buffer does not contain a null terminator, it just
inherits the non-failing regular strlcat behavior.

Reviewed-by: Siddhesh Poyarekar &lt;siddhesh@sourceware.org&gt;
</content>
</entry>
<entry>
<title>String: Add support for __memcmpeq() ABI on all targets</title>
<updated>2021-10-26T21:51:29Z</updated>
<author>
<name>Noah Goldstein</name>
<email>goldstein.w.n@gmail.com</email>
</author>
<published>2021-10-21T20:54:57Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=44829b3ddb64e99e37343a0f25b2c082387d31a5'/>
<id>urn:sha1:44829b3ddb64e99e37343a0f25b2c082387d31a5</id>
<content type='text'>
No bug.

This commit adds support for __memcmpeq() as a new ABI for all
targets. In this commit __memcmpeq() is implemented only as an alias
to the corresponding targets memcmp() implementation. __memcmpeq() is
added as a new symbol starting with GLIBC_2.35 and defined in string.h
with comments explaining its behavior. Basic tests that it is callable
and works where added in string/tester.c

As discussed in the proposal "Add new ABI '__memcmpeq()' to libc"
__memcmpeq() is essentially a reserved namespace for bcmp(). The means
is shares the same specifications as memcmp() except the return value
for non-equal byte sequences is any non-zero value. This is less
strict than memcmp()'s return value specification and can be better
optimized when a boolean return is all that is needed.

__memcmpeq() is meant to only be called by compilers if they can prove
that the return value of a memcmp() call is only used for its boolean
value.

All tests in string/tester.c passed. As well build succeeds on
x86_64-linux-gnu target.
</content>
</entry>
<entry>
<title>string: Add strerrorname_np and strerrordesc_np</title>
<updated>2020-07-07T18:02:57Z</updated>
<author>
<name>Adhemerval Zanella</name>
<email>adhemerval.zanella@linaro.org</email>
</author>
<published>2020-05-18T20:41:25Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=325081b9eb2035f8f025255206889208f330b590'/>
<id>urn:sha1:325081b9eb2035f8f025255206889208f330b590</id>
<content type='text'>
The strerrorname_np returns error number name (e.g. "EINVAL" for EINVAL)
while strerrordesc_np returns string describing error number (e.g
"Invalid argument" for EINVAL).  Different than strerror,
strerrordesc_np does not attempt to translate the return description,
both functions return NULL for an invalid error number.

They should be used instead of sys_errlist and sys_nerr, both are
thread and async-signal safe.  These functions are GNU extensions.

Checked on x86-64-linux-gnu, i686-linux-gnu, powerpc64le-linux-gnu,
and s390x-linux-gnu.

Tested-by: Carlos O'Donell &lt;carlos@redhat.com&gt;
Reviewed-by: Carlos O'Donell &lt;carlos@redhat.com&gt;
</content>
</entry>
<entry>
<title>string: Add sigabbrev_np and sigdescr_np</title>
<updated>2020-07-07T17:57:14Z</updated>
<author>
<name>Adhemerval Zanella</name>
<email>adhemerval.zanella@linaro.org</email>
</author>
<published>2020-05-18T20:05:05Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=bfe05aa289054744b68f136b701705cfd242c4de'/>
<id>urn:sha1:bfe05aa289054744b68f136b701705cfd242c4de</id>
<content type='text'>
The sigabbrev_np returns the abbreviated signal name (e.g. "HUP" for
SIGHUP) while sigdescr_np returns the string describing the error
number (e.g "Hangup" for SIGHUP).  Different than strsignal,
sigdescr_np does not attempt to translate the return description and
both functions return NULL for an invalid signal number.

They should be used instead of sys_siglist or sys_sigabbrev and they
are both thread and async-signal safe.  They are added as GNU
extensions on string.h header (same as strsignal).

Checked on x86-64-linux-gnu, i686-linux-gnu, powerpc64le-linux-gnu,
and s390x-linux-gnu.

Tested-by: Carlos O'Donell &lt;carlos@redhat.com&gt;
Reviewed-by: Carlos O'Donell &lt;carlos@redhat.com&gt;
</content>
</entry>
<entry>
<title>New string function explicit_bzero (from OpenBSD).</title>
<updated>2016-12-16T21:21:54Z</updated>
<author>
<name>Zack Weinberg</name>
<email>zackw@panix.com</email>
</author>
<published>2016-09-15T11:29:44Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=ea1bd74defcf9d5291d14972e63105168ca9eb4f'/>
<id>urn:sha1:ea1bd74defcf9d5291d14972e63105168ca9eb4f</id>
<content type='text'>
explicit_bzero(s, n) is the same as memset(s, 0, n), except that the
compiler is not allowed to delete a call to explicit_bzero even if the
memory pointed to by 's' is dead after the call.  Right now, this effect
is achieved externally by having explicit_bzero be a function whose
semantics are unknown to the compiler, and internally, with a no-op
asm statement that clobbers memory.  This does mean that small
explicit_bzero operations cannot be expanded inline as small memset
operations can, but on the other hand, small memset operations do get
deleted by the compiler.  Hopefully full compiler support for
explicit_bzero will happen relatively soon.

There are two new tests: test-explicit_bzero.c verifies the
visible semantics in the same way as the existing test-bzero.c,
and tst-xbzero-opt.c verifies the not-being-optimized-out property.
The latter is conceptually based on a test written by Matthew Dempsky
for the OpenBSD regression suite.

The crypt() implementation has an immediate use for this new feature.
We avoid having to add a GLIBC_PRIVATE alias for explicit_bzero
by running all of libcrypt's calls through the fortified variant,
__explicit_bzero_chk, which is in the impl namespace anyway.  Currently
I'm not aware of anything in libc proper that needs this, but the
glue is all in place if it does become necessary.  The legacy DES
implementation wasn't bothering to clear its buffers, so I added that,
mostly for consistency's sake.

	* string/explicit_bzero.c: New routine.
	* string/test-explicit_bzero.c, string/tst-xbzero-opt.c: New tests.
	* string/Makefile (routines, strop-tests, tests): Add them.
	* string/test-memset.c: Add ifdeffage for testing explicit_bzero.
	* string/string.h [__USE_MISC]: Declare explicit_bzero.

	* debug/explicit_bzero_chk.c: New routine.
	* debug/Makefile (routines): Add it.
	* debug/tst-chk1.c: Test fortification of explicit_bzero.
	* string/bits/string3.h: Fortify explicit_bzero.

	* manual/string.texi: Document explicit_bzero.
	* NEWS: Mention addition of explicit_bzero.

	* crypt/crypt-entry.c (__crypt_r): Clear key-dependent intermediate
	data before returning, using explicit_bzero.
	* crypt/md5-crypt.c (__md5_crypt_r): Likewise.
	* crypt/sha256-crypt.c (__sha256_crypt_r): Likewise.
	* crypt/sha512-crypt.c (__sha512_crypt_r): Likewise.

	* include/string.h: Redirect internal uses of explicit_bzero
	to __explicit_bzero_chk[_internal].
	* string/Versions [GLIBC_2.25]: Add explicit_bzero.
	* debug/Versions [GLIBC_2.25]: Add __explicit_bzero_chk.
	* sysdeps/arm/nacl/libc.abilist
	* sysdeps/unix/sysv/linux/aarch64/libc.abilist
	* sysdeps/unix/sysv/linux/alpha/libc.abilist
	* sysdeps/unix/sysv/linux/arm/libc.abilist
	* sysdeps/unix/sysv/linux/hppa/libc.abilist
	* sysdeps/unix/sysv/linux/i386/libc.abilist
	* sysdeps/unix/sysv/linux/ia64/libc.abilist
	* sysdeps/unix/sysv/linux/m68k/coldfire/libc.abilist
	* sysdeps/unix/sysv/linux/m68k/m680x0/libc.abilist
	* sysdeps/unix/sysv/linux/microblaze/libc.abilist
	* sysdeps/unix/sysv/linux/mips/mips32/fpu/libc.abilist
	* sysdeps/unix/sysv/linux/mips/mips32/nofpu/libc.abilist
	* sysdeps/unix/sysv/linux/mips/mips64/n32/libc.abilist
	* sysdeps/unix/sysv/linux/mips/mips64/n64/libc.abilist
	* sysdeps/unix/sysv/linux/nios2/libc.abilist
	* sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/libc.abilist
	* sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/libc.abilist
	* sysdeps/unix/sysv/linux/powerpc/powerpc64/libc-le.abilist
	* sysdeps/unix/sysv/linux/powerpc/powerpc64/libc.abilist
	* sysdeps/unix/sysv/linux/s390/s390-32/libc.abilist
	* sysdeps/unix/sysv/linux/s390/s390-64/libc.abilist
	* sysdeps/unix/sysv/linux/sh/libc.abilist
	* sysdeps/unix/sysv/linux/sparc/sparc32/libc.abilist
	* sysdeps/unix/sysv/linux/sparc/sparc64/libc.abilist
	* sysdeps/unix/sysv/linux/tile/tilegx/tilegx32/libc.abilist
	* sysdeps/unix/sysv/linux/tile/tilegx/tilegx64/libc.abilist
	* sysdeps/unix/sysv/linux/tile/tilepro/libc.abilist
	* sysdeps/unix/sysv/linux/x86_64/64/libc.abilist
	* sysdeps/unix/sysv/linux/x86_64/x32/libc.abilist:
	Add entries for explicit_bzero and __explicit_bzero_chk.
</content>
</entry>
<entry>
<title>Improve generic strcspn performance</title>
<updated>2016-04-01T13:44:40Z</updated>
<author>
<name>Wilco Dijkstra</name>
<email>wdijkstr@arm.com</email>
</author>
<published>2016-03-25T19:44:26Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=d3496c9f4f27d3009b71be87f6108b4fed7314bd'/>
<id>urn:sha1:d3496c9f4f27d3009b71be87f6108b4fed7314bd</id>
<content type='text'>
Improve strcspn performance using a much faster algorithm.  It is kept simple
so it works well on most targets.  It is generally at least 10 times faster
than the existing implementation on bench-strcspn on a few AArch64
implementations, and for some tests 100 times as fast (repeatedly calling
strchr on a small string is extremely slow...).

In fact the string/bits/string2.h inlines make no longer sense, as GCC
already uses strlen if reject is an empty string, strchrnul is 5 times as
fast as __strcspn_c1, while __strcspn_c2 and __strcspn_c3 are slower than
the strcspn main loop for large strings (though reject length 2-4 could be
special cased in the future to gain even more performance).

Tested on x86_64, i686, and aarch64.

	* string/Version (libc): Add GLIBC_2.24.
	* string/strcspn.c (strcspn): Rewrite function.
	* string/bits/string2.h (strcspn): Use __builtin_strcspn.
	(__strcspn_c1): Remove inline function.
	(__strcspn_c2): Likewise.
	(__strcspn_c3): Likewise.
	* string/string-inline.c
	[SHLIB_COMPAT(libc, GLIBC_2_1_1, GLIBC_2_24)] (__strcspn_c1): Add
	compatibility symbol.
	[SHLIB_COMPAT(libc, GLIBC_2_1_1, GLIBC_2_24)] (__strcspn_c2):
	Likewise.
	[SHLIB_COMPAT(libc, GLIBC_2_1_1, GLIBC_2_24)] (__strcspn_c3):
	Likewise.
	* sysdeps/i386/string-inlines.c: Include generic string-inlines.c.
</content>
</entry>
<entry>
<title>Sort Versions files</title>
<updated>2013-02-17T15:34:04Z</updated>
<author>
<name>Andreas Jaeger</name>
<email>aj@suse.de</email>
</author>
<published>2013-02-17T15:26:35Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=f238fd190bbfc57f5678ca5c5975b92bfb21e040'/>
<id>urn:sha1:f238fd190bbfc57f5678ca5c5975b92bfb21e040</id>
<content type='text'>
</content>
</entry>
<entry>
<title>* sysdeps/unix/sysv/linux/i386/sysdep.h (PTR_MANGLE): Roll value before</title>
<updated>2007-02-01T16:14:15Z</updated>
<author>
<name>Ulrich Drepper</name>
<email>drepper@redhat.com</email>
</author>
<published>2007-02-01T16:14:15Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=4a44ce79c6dee9a77207466142a36caa9fa54141'/>
<id>urn:sha1:4a44ce79c6dee9a77207466142a36caa9fa54141</id>
<content type='text'>
	returning.
	(PTR_DEMANGLE): Real definition now that it's not the same as
	PRT_MANGLE anymore.
	* sysdeps/unix/sysv/linux/x86_64/sysdep.h: Likewise.

	* string/strerror_l.c: New file.
	* string/Makefile (routines): Add strerror_l.
	* string/string.h: Declare strerror_l.
	* string/Versions: Export strerror_l for GLIBC_2.6.

	* nscd/connections.c (nscd_run): Don't define MAXKEYLEN here.
</content>
</entry>
<entry>
<title>Update.</title>
<updated>2004-03-22T19:54:06Z</updated>
<author>
<name>Ulrich Drepper</name>
<email>drepper@redhat.com</email>
</author>
<published>2004-03-22T19:54:06Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=61645263d4b3c72c9a33659a0fcabe1dd2814a98'/>
<id>urn:sha1:61645263d4b3c72c9a33659a0fcabe1dd2814a98</id>
<content type='text'>
2004-03-22  Jakub Jelinek  &lt;jakub@redhat.com&gt;

	* sysdeps/unix/sysv/linux/sparc/sparc32/getpagesize.c
	(__getpagesize): Avoid warning about writing into read-only memory.

	* string/Makefile (routines): Add xpg-strerror.
	* string/string.h (strerror_r): If __USE_XOPEN2K but not __USE_GNU,
	redirect strerror_r to __xpg_strerror_r.
	* string/Versions (libc): Add __xpg_strerror_r@@GLIBC_2.3.4.
	* sysdeps/generic/xpg-strerror.c: New file.
	* sysdeps/mach/xpg-strerror.c: New file.
</content>
</entry>
<entry>
<title>Update.</title>
<updated>2001-10-07T20:26:31Z</updated>
<author>
<name>Ulrich Drepper</name>
<email>drepper@redhat.com</email>
</author>
<published>2001-10-07T20:26:31Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/glibc/commit/?id=b61345a1add0789a12fe341563374d64b5134771'/>
<id>urn:sha1:b61345a1add0789a12fe341563374d64b5134771</id>
<content type='text'>
2001-10-04  Ben Collins  &lt;bcollins@debian.org&gt;

	* sysdeps/generic/inttypes.h: Fix typo (define, not defined) in
	decleration of __need_wchar_t.

2001-10-03  Jakub Jelinek  &lt;jakub@redhat.com&gt;

	* string/bits/string2.h (__strsep_g): Add prototype.
	(__strsep): Use it.
	* string/Versions (__strsep): Remove.
	* sysdeps/generic/strsep.c (__strsep_g): Add alias to __strsep.

2001-10-07  Ulrich Drepper  &lt;drepper@redhat.com&gt;

	* manua/llio.texi: Clarify file references added by mmap.
	Patch by Marcus Brinkmann &lt;Marcus.Brinkmann@ruhr-uni-bochum.de&gt;.
</content>
</entry>
</feed>
