Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 Jan 1995 18:58:48 -0500
From:      Garrett Wollman <wollman@halloran-eldar.lcs.mit.edu>
To:        terry@cs.weber.edu (Terry Lambert)
Cc:        roberto@blaise.ibp.fr (Ollivier ROBERT), jkh@freefall.cdrom.com, hackers@freefall.cdrom.com
Subject:   Re: Optimizing CVS?
Message-ID:  <9501312358.AA18319@halloran-eldar.lcs.mit.edu>
In-Reply-To: <9501312131.AA28664@cs.weber.edu>
References:  <9501310915.AA04063@blaise.ibp.fr> <9501312131.AA28664@cs.weber.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
<<On Tue, 31 Jan 95 14:31:28 MST, terry@cs.weber.edu (Terry Lambert) said:

> Finally, the inode cache needs to be moved over to a vnode cache instead,
> and generalized at the comsumer level for the file system (ie: moved the
> hell out of UFS).  SVR4 actually has this one right with their DNLC
> mechanism, although they (incorrectly) do not allow for use of the DNLC
> as a negative hit cache.

Gee, this sure looks like a vnode cache to me...

/*
 * Look for a the name in the cache. We don't do this
 * if the segment name is long, simply so the cache can avoid
 * holding long names (which would either waste space, or
 * add greatly to the complexity).
 *
 * Lookup is called with ni_dvp pointing to the directory to search,
 * ni_ptr pointing to the name of the entry being sought, ni_namelen
 * tells the length of the name, and ni_hash contains a hash of
 * the name. If the lookup succeeds, the vnode is returned in ni_vp
 * and a status of -1 is returned. If the lookup determines that
 * the name does not exist (negative cacheing), a status of ENOENT
 * is returned. If the lookup fails, a status of zero is returned.
 */
int
cache_lookup(dvp, vpp, cnp)
        struct vnode *dvp;
        struct vnode **vpp;
        struct componentname *cnp;

-GAWollman

--
Garrett A. Wollman   | Shashish is simple, it's discreet, it's brief. ... 
wollman@lcs.mit.edu  | Shashish is the bonding of hearts in spite of distance.
Opinions not those of| It is a bond more powerful than absence.  We like people
MIT, LCS, ANA, or NSA| who like Shashish.  - Claude McKenzie + Florent Vollant



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9501312358.AA18319>