Home
last modified time | relevance | path

Searched hist:fb197a4f7751bb4e116989e57ba7fb12a981895f (Results 1 – 2 of 2) sorted by relevance

/freebsd/lib/libc/amd64/string/
H A Dmemrchr.Sfb197a4f7751bb4e116989e57ba7fb12a981895f Wed Dec 06 11:05:47 CET 2023 Robert Clausecker <fuz@FreeBSD.org> lib/libc/amd64/string: add memrchr() scalar, baseline implementation

The scalar implementation is fairly simplistic and only performs
slightly better than the generic C implementation. It could be
improved by using the same algorithm as for memchr, but it would
have been a lot more complicated.

The baseline implementation is similar to timingsafe_memcmp. It's
slightly slower than memchr() due to the more complicated main
loop, but I don't think that can be significantly improved.

Tested by: developers@, exp-run
Approved by: mjg
MFC after: 1 month
MFC to: stable/14
PR: 275785
Differential Revision: https://reviews.freebsd.org/D42925
H A DMakefile.incdiff fb197a4f7751bb4e116989e57ba7fb12a981895f Wed Dec 06 11:05:47 CET 2023 Robert Clausecker <fuz@FreeBSD.org> lib/libc/amd64/string: add memrchr() scalar, baseline implementation

The scalar implementation is fairly simplistic and only performs
slightly better than the generic C implementation. It could be
improved by using the same algorithm as for memchr, but it would
have been a lot more complicated.

The baseline implementation is similar to timingsafe_memcmp. It's
slightly slower than memchr() due to the more complicated main
loop, but I don't think that can be significantly improved.

Tested by: developers@, exp-run
Approved by: mjg
MFC after: 1 month
MFC to: stable/14
PR: 275785
Differential Revision: https://reviews.freebsd.org/D42925