diff options
author | Peter Wemm <peter@FreeBSD.org> | 2001-03-17 09:31:06 +0000 |
---|---|---|
committer | Peter Wemm <peter@FreeBSD.org> | 2001-03-17 09:31:06 +0000 |
commit | 6eb39ac8fca93d24eae9ae99ce93b0051a3bba72 (patch) | |
tree | d54e4b1c6b4a97ff4af8376ef41b677b3849efa0 /sys/nfsserver | |
parent | 0c5c7719e63c6b5f828db5fa22f2c89dfa9d53ac (diff) | |
download | src-6eb39ac8fca93d24eae9ae99ce93b0051a3bba72.tar.gz src-6eb39ac8fca93d24eae9ae99ce93b0051a3bba72.zip |
Use a generic implementation of the Fowler/Noll/Vo hash (FNV hash).
Make the name cache hash as well as the nfsnode hash use it.
As a special tweak, create an unsigned version of register_t. This allows
us to use a special tweak for the 64 bit versions that significantly
speeds up the i386 version (ie: int64 XOR int64 is slower than int64
XOR int32).
The code layout is a little strange for the string function, but I was
able to get between 5 to 10% improvement over the original version I
started with. The layout affects gcc code generation choices and this way
was fastest on x86 and alpha.
Note that 'CPUTYPE=p3' etc makes a fair difference to this. It is
around 45% faster with -march=pentiumpro on a p6 cpu.
Notes
Notes:
svn path=/head/; revision=74384
Diffstat (limited to 'sys/nfsserver')
-rw-r--r-- | sys/nfsserver/nfs.h | 1 | ||||
-rw-r--r-- | sys/nfsserver/nfsrvstats.h | 1 |
2 files changed, 0 insertions, 2 deletions
diff --git a/sys/nfsserver/nfs.h b/sys/nfsserver/nfs.h index 6423e5ac6af6..259ec2067384 100644 --- a/sys/nfsserver/nfs.h +++ b/sys/nfsserver/nfs.h @@ -633,7 +633,6 @@ int nfs_savenickauth __P((struct nfsmount *, struct ucred *, int, int nfs_adv __P((struct mbuf **, caddr_t *, int, int)); void nfs_nhinit __P((void)); void nfs_timer __P((void*)); -u_long nfs_hash __P((nfsfh_t *, int)); int nfsrv_dorec __P((struct nfssvc_sock *, struct nfsd *, struct nfsrv_descript **)); int nfsrv_getcache __P((struct nfsrv_descript *, struct nfssvc_sock *, diff --git a/sys/nfsserver/nfsrvstats.h b/sys/nfsserver/nfsrvstats.h index 6423e5ac6af6..259ec2067384 100644 --- a/sys/nfsserver/nfsrvstats.h +++ b/sys/nfsserver/nfsrvstats.h @@ -633,7 +633,6 @@ int nfs_savenickauth __P((struct nfsmount *, struct ucred *, int, int nfs_adv __P((struct mbuf **, caddr_t *, int, int)); void nfs_nhinit __P((void)); void nfs_timer __P((void*)); -u_long nfs_hash __P((nfsfh_t *, int)); int nfsrv_dorec __P((struct nfssvc_sock *, struct nfsd *, struct nfsrv_descript **)); int nfsrv_getcache __P((struct nfsrv_descript *, struct nfssvc_sock *, |