<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/lib/libc/string, branch releng/13.1</title>
<subtitle>FreeBSD source tree</subtitle>
<id>http://cgit.freebsd.org/src/atom?h=releng%2F13.1</id>
<link rel='self' href='http://cgit.freebsd.org/src/atom?h=releng%2F13.1'/>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/'/>
<updated>2022-01-19T00:32:29Z</updated>
<entry>
<title>libc: correct SPDX tag on strstr.c</title>
<updated>2022-01-19T00:32:29Z</updated>
<author>
<name>Ed Maste</name>
<email>emaste@FreeBSD.org</email>
</author>
<published>2022-01-16T16:56:28Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=423fb85f33578988c28524bcfd41f967a4d1bf5d'/>
<id>urn:sha1:423fb85f33578988c28524bcfd41f967a4d1bf5d</id>
<content type='text'>
It was obtained from musl, and is MIT licensed.

MFC after:	3 days
Sponsored by:	The FreeBSD Foundation

(cherry picked from commit 2e9bc9d14440aa17e6945a9b6613ebb1711fe960)
</content>
</entry>
<entry>
<title>libc: fix misleading comment in strstr</title>
<updated>2022-01-19T00:32:29Z</updated>
<author>
<name>Ed Maste</name>
<email>emaste@FreeBSD.org</email>
</author>
<published>2022-01-16T16:50:10Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=e475c5f6ca278639821a4668ea2f1e515383efb7'/>
<id>urn:sha1:e475c5f6ca278639821a4668ea2f1e515383efb7</id>
<content type='text'>
Obtained from:	musl c53e9b239418

(cherry picked from commit c6750f07b43d18d39729570533f4ecb56da286bf)
</content>
</entry>
<entry>
<title>libc: Use musl's optimized strchr and strchrnul</title>
<updated>2021-12-12T22:32:33Z</updated>
<author>
<name>Ed Maste</name>
<email>emaste@FreeBSD.org</email>
</author>
<published>2021-03-02T01:57:36Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=bf4a70bb405cbc5e0ecf1babe0e55c220964e46c'/>
<id>urn:sha1:bf4a70bb405cbc5e0ecf1babe0e55c220964e46c</id>
<content type='text'>
Parentheses added to HASZERO macro to avoid a GCC warning, and formatted
with clang-format as we have adopted these and don't consider them
'contrib' code.

Obtained from:	musl (snapshot at commit 4d0a82170a25)
Reviewed by:	kib (libc integration), mjg (both earlier)
MFC after:	1 month
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D17630

(cherry picked from commit 7f72497ef756ff7d03d5560c2d1c1f92f73fcb52)
</content>
</entry>
<entry>
<title>libc: add mempcpy(3) and wmempcpy(3)</title>
<updated>2021-07-22T10:33:10Z</updated>
<author>
<name>Konstantin Belousov</name>
<email>kib@FreeBSD.org</email>
</author>
<published>2021-07-14T15:41:36Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=dba677d13b26ad5422133b2ab76486b74d63ade4'/>
<id>urn:sha1:dba677d13b26ad5422133b2ab76486b74d63ade4</id>
<content type='text'>
(cherry picked from commit ee37f64cf875255338f917a9da76c643cf59786c)
</content>
</entry>
<entry>
<title>libc/string/memset.c: Use unsigned long for stores</title>
<updated>2021-05-11T08:39:27Z</updated>
<author>
<name>Alex Richardson</name>
<email>arichardson@FreeBSD.org</email>
</author>
<published>2021-04-19T23:19:20Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=fc19e3cb4fd1403a6c6dba3c9879db031faa9df3'/>
<id>urn:sha1:fc19e3cb4fd1403a6c6dba3c9879db031faa9df3</id>
<content type='text'>
While most 64-bit architectures have an assembly implementation of this
file, RISC-V does not. As we now store 8 bytes instead of 4 it should speed
up RISC-V.

Reviewed By:	kib
MFC after:	1 week
Differential Revision: https://reviews.freebsd.org/D29536

(cherry picked from commit ab147542b7c0bbc41f7f0499b16933bd8f3f31d7)
</content>
</entry>
<entry>
<title>libc/string/bcopy.c: Use intptr_t as the copy type</title>
<updated>2021-05-11T08:39:26Z</updated>
<author>
<name>Alex Richardson</name>
<email>arichardson@FreeBSD.org</email>
</author>
<published>2021-04-19T23:15:57Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=0e1e71400a0fa3ac6fe5a90c4d830b06eef3e71e'/>
<id>urn:sha1:0e1e71400a0fa3ac6fe5a90c4d830b06eef3e71e</id>
<content type='text'>
While most 64-bit architectures have an assembly implementation of this
file RISC-V does not. As we now copy 8 bytes instead of 4 it should speed
up RISC-V. Using intptr_t instead of int also allows using this file for
CHERI pure-capability code since trying to copy pointers using integer
loads/stores will invalidate pointers.

Reviewed By:	kib
Obtained from:	CheriBSD (partially)
MFC after:	1 week
Differential Revision: https://reviews.freebsd.org/D29535

(cherry picked from commit 0b4ad01d91a3b24cea00d54d25beed0f487c0183)
</content>
</entry>
<entry>
<title>Remove __NO_TLS.</title>
<updated>2021-03-02T00:49:42Z</updated>
<author>
<name>Konstantin Belousov</name>
<email>kib@FreeBSD.org</email>
</author>
<published>2021-02-19T15:20:29Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=73dc6674e08c40151c1500860f60f7b22994a0ff'/>
<id>urn:sha1:73dc6674e08c40151c1500860f60f7b22994a0ff</id>
<content type='text'>
MFC note: this plus the merge of two preliminary removal of __NO_TLS
definitions for mips and risc-v break ABI.  It was decided that doing
ABI break on tier 2 platforms at this stage of 13.0 release process is
better than drag on __NO_TLS presence for the 13.x branch lifetime.

(cherry picked from commit 3ae8d83d04a7a6ec11b64c89ee60c180b0bde30e)
</content>
</entry>
<entry>
<title>Revert "Reimplement strlen"</title>
<updated>2021-02-03T19:39:49Z</updated>
<author>
<name>Mateusz Guzik</name>
<email>mjg@FreeBSD.org</email>
</author>
<published>2021-02-03T19:38:10Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=8a680912a190d619be6194f88917052eed327f7b'/>
<id>urn:sha1:8a680912a190d619be6194f88917052eed327f7b</id>
<content type='text'>
This reverts commit 710e45c4b8539d028877769f1a4ec088c48fb5f1.

It breaks for some corner cases on big endian ppc64.
Given the stage of the release process it is best to revert for now.

Reported by:	jhibbits

(cherry picked from commit 33f0540b13d949c7cc226a79927ddc2062ff98bf)
</content>
</entry>
<entry>
<title>Reimplement strlen</title>
<updated>2021-02-01T12:39:18Z</updated>
<author>
<name>Mateusz Guzik</name>
<email>mjg@FreeBSD.org</email>
</author>
<published>2021-01-29T21:48:11Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=e5b674594e64b86a34295a475bb6cdb67469f8da'/>
<id>urn:sha1:e5b674594e64b86a34295a475bb6cdb67469f8da</id>
<content type='text'>
The previous code neglected to use primitives which can find the end
of the string without having to branch on every character.

While here augment the somewhat misleading commentary -- strlen as
implemented here leaves performance on the table, especially so for
userspace. Every arch should get a dedicated variant instead.

In the meantime this commit lessens the problem.

Tested with glibc test suite.

Naive test just calling strlen in a loop on Haswell (ops/s):

$(perl -e "print 'A' x 3"):
before:	211198039
after:	338626619

$(perl -e "print 'A' x 100"):
before:	83151997
after:	98285919

(cherry picked from commit 710e45c4b8539d028877769f1a4ec088c48fb5f1)
</content>
</entry>
<entry>
<title>strerror.3: Fix whitespace issue introduced in r368714</title>
<updated>2020-12-18T22:10:17Z</updated>
<author>
<name>Jessica Clarke</name>
<email>jrtc27@FreeBSD.org</email>
</author>
<published>2020-12-18T22:10:17Z</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=ccb86b40c172e14b454b44ca52750c24939355ea'/>
<id>urn:sha1:ccb86b40c172e14b454b44ca52750c24939355ea</id>
<content type='text'>
MFC with:	368714
</content>
</entry>
</feed>
