svn commit: r229198 - in head: share/man/man9 sys/conf sys/libkern sys/sys

Pawel Jakub Dawidek pjd at FreeBSD.org
Tue Jan 3 15:53:32 UTC 2012


On Sun, Jan 01, 2012 at 08:26:11PM +0000, Ed Schouten wrote:
> Author: ed
> Date: Sun Jan  1 20:26:11 2012
> New Revision: 229198
> URL: http://svn.freebsd.org/changeset/base/229198
> 
> Log:
>   Introducing memcchr(3).
>   
>   It seems two of the file system drivers we have in the tree, namely ufs
>   and ext3, use a function called `skpc()'. The meaning of this function
>   does not seem to be documented in FreeBSD, but it turns out one needs to
>   be a VAX programmer to understand what it does.
>   
>   SPKC is an instruction on the VAX that does the opposite of memchr(). It
>   searches for the non-equal character. Add a new function called
>   memcchr() to the tree that has the following advantages over skpc():
>   
>   - It has a name that makes more sense than skpc(). Just like strcspn()
>     matches the complement of strspn(), memcchr() is the complement of
>     memchr().
>   
>   - It is faster than skpc(). Similar to our strlen() in libc, it compares
>     entire words, instead of single bytes. It seems that for this routine
>     this yields a sixfold performance increase on amd64.
>   
>   - It has a man page.
> 
> Added:
>   head/share/man/man9/memcchr.3   (contents, props changed)

Shouldn't this be memcchr.9?

-- 
Pawel Jakub Dawidek                       http://www.wheelsystems.com
FreeBSD committer                         http://www.FreeBSD.org
Am I Evil? Yes, I Am!                     http://yomoli.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/svn-src-all/attachments/20120103/63bf6bc3/attachment.pgp


More information about the svn-src-all mailing list