freebsd-dev/sys/sys
Poul-Henning Kamp bff1f1d0dd Clean up and improve the namecache.
1. We always keep one 16th of the vnodes on the freelist, so that the
namecache doesn't get trashed.  It used to be that it wasn't a problem, but
the only vnodes getting released these days are directories and things which
Clean up and improve the namecache.

1. We always keep one 16th of the vnodes on the freelist, so that the
namecache doesn't get trashed.  It used to be that it wasn't a problem, but
the only vnodes getting released these days are directories and things which
gets forced out of the VM/cache.  The latter is not numerous enough to keep
the pool of vnodes needed for the namecache sufficiently big.

2. Purge invalid entries in the namecache as soon as we notice them.  This
avoids a stale entry pushing out a valid entry on the LRU list.

3. Speed up the lookup in the namecache by avoid a special case branch.

4. Make the cache purge routines do the thing they're supposed to, and in
a decently efficient manner.

5. Make the size of the namecache follow the number of vnodes, so that we
can always point to all the vnodes we have in core.

6. Readability has gone way up.

7. Added a "options NCH_STATISTICS" feature that will gather more
detailed statistics on the performance of the namecache.

Reviewed by:    davidg
1995-03-09 20:27:21 +00:00
..
_sigset.h Correct a name of one structure member in the sigaltstack structure. 1995-01-29 01:19:25 +00:00
acct.h Process accounting implementation by Chris Demetriou, with minor local 1994-09-26 21:09:15 +00:00
bio.h New field b_biodone_chain to support nested b_iodone's. 1995-02-18 21:12:33 +00:00
bitstring.h BSD 4.4 Lite Include Sources 1994-05-24 09:57:34 +00:00
buf.h New field b_biodone_chain to support nested b_iodone's. 1995-02-18 21:12:33 +00:00
callout.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
cdefs.h Warning and weak reference macros which are used to generate link-time 1994-12-23 22:38:54 +00:00
cdio.h Replaced certain character arrays in structures with msf_lba union. 1994-02-05 09:14:24 +00:00
chio.h New version of scsi code from Julian 1993-11-18 05:03:27 +00:00
clist.h Got rid of unused nclist declaration. 1995-01-07 06:08:15 +00:00
conf.h (a) remove the pointer to each driver's tty structure array from cdevsw 1995-02-25 20:09:44 +00:00
cons.h Peter Dufaults comconsole changes. 1994-10-20 00:08:31 +00:00
devconf.h Finished device configuration database work for all ISA devices (except `ze') 1994-10-23 21:28:03 +00:00
device.h Added $Id$ 1994-08-02 07:55:43 +00:00
dir.h Added $Id$ 1994-08-02 07:55:43 +00:00
dirent.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
disk.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
disklabel.h Add a prototype. 1995-02-22 21:24:21 +00:00
diskmbr.h Add a prototype. 1995-02-22 21:24:21 +00:00
diskpc98.h Add a prototype. 1995-02-22 21:24:21 +00:00
diskslice.h Add a type field to struct diskslice. 1995-03-04 11:05:44 +00:00
dkbad.h disklabel.h: 1994-12-11 23:20:50 +00:00
dkstat.h Fix comments on dk_wds and dk_wpms to match code. Improve comment on 1994-12-24 10:11:18 +00:00
dmap.h Added $Id$ 1994-08-02 07:55:43 +00:00
domain.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
errno.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
exec.h Latest ibcs2 changes, add errno conversion table. 1994-10-09 21:50:57 +00:00
fbio.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
fcntl.h Added $Id$ 1994-08-02 07:55:43 +00:00
fdcio.h Included the command definition for FD_DEBUG. 1994-10-30 19:17:39 +00:00
file.h Implement maxprocperuid and maxfilesperproc. They are tunable 1995-02-20 19:42:42 +00:00
filedesc.h Prototypes, prototypes and even more prototypes. Not quite done yet, but 1994-10-02 17:25:04 +00:00
filio.h Added $Id$ 1994-08-02 07:55:43 +00:00
ftape.h Pulled over missing ftape.h from 1.1.5 1994-08-14 01:52:48 +00:00
gmon.h Define MAXARCS correctly. It has nothing to do with HISTCOUNTER, and 1995-01-29 06:23:34 +00:00
imgact_aout.h Avoid compiler warnings for overflow in ~(__LDPGSZ - 1). 1994-12-30 08:06:19 +00:00
imgact.h Prototypes, prototypes and even more prototypes. Not quite done yet, but 1994-10-02 17:25:04 +00:00
inflate.h I belive imgact_gzip is finally reentrant. It is also a whole lot more 1994-10-22 11:40:38 +00:00
ioccom.h Added $Id$ 1994-08-02 07:55:43 +00:00
ioctl_compat.h Added $Id$ 1994-08-02 07:55:43 +00:00
ioctl.h Added $Id$ 1994-08-02 07:55:43 +00:00
ipc.h Fix specification of octal constants. 1994-12-30 05:38:14 +00:00
joystick.h Put the joystick status in a struct {int x, y, b1, b2;} rather than in a 1995-02-22 23:34:58 +00:00
kernel.h Define a new macro. PSEUDO_SET, to hide TEXT_SET(pseudo_set, foo) 1994-10-05 21:23:38 +00:00
ktrace.h Prototypes, prototypes and even more prototypes. Not quite done yet, but 1994-10-02 17:25:04 +00:00
libkern.h Hide the declaration of ffs() if an inline ffs() is implemented. 1994-11-14 14:56:46 +00:00
linedisc.h (a) remove the pointer to each driver's tty structure array from cdevsw 1995-02-25 20:09:44 +00:00
link_aout.h Weak symbol support from NetBSD. This should bring us in sync with the 1995-03-04 17:49:20 +00:00
link_elf.h Weak symbol support from NetBSD. This should bring us in sync with the 1995-03-04 17:49:20 +00:00
lkm.h ktrace.c: added decl of ktrnamei 1994-09-27 20:39:54 +00:00
lockf.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
malloc.h Calling semantics for kmem_malloc() have been changed...and the third 1995-02-02 08:49:45 +00:00
map.h Removed unimplemented subr_rmap.c and unused references to it. 1994-09-25 22:31:11 +00:00
mbuf.h Declare a complete prototype for the function pointer *ext_free and the 1994-11-14 13:54:20 +00:00
md5.h Added "const" to the arguments here and there. 1994-11-07 20:48:35 +00:00
mdioctl.h ioctl definitions for the vn driver. 1994-12-04 20:09:16 +00:00
mman.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
mount.h Actually implement the functionality documented in sysctl.h for type CTL_FS. 1994-10-20 00:48:28 +00:00
mouse.h Added the psm driver from 1.1.5. 1994-09-09 11:27:50 +00:00
msg.h Got rid of compiler warnings. 1994-09-17 13:24:29 +00:00
msgbuf.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
mtio.h Andreas Klemm's tape erase patches from 1.1.5.1 1994-10-28 13:19:42 +00:00
namei.h Clean up and improve the namecache. 1995-03-09 20:27:21 +00:00
nlist_aout.h Document some of the fields used by the new shlib code. 1994-12-23 22:32:48 +00:00
param.h Changed maximum number of symlinks in a path from 8 to 32. The exact value 1995-02-07 03:33:05 +00:00
proc.h Added missing extern declaration for 'maxprocperuid'. 1995-02-21 00:37:31 +00:00
protosw.h Merge in the socket-level support for Transaction TCP from the OLAH_TTCP 1995-02-07 02:01:57 +00:00
ptrace.h Process tracing code. Written by Sean Eric Fagan. 1994-08-08 13:00:27 +00:00
queue.h Added $Id$ 1994-08-02 07:55:43 +00:00
reboot.h Add flag RB_BOOTINFO' that tells if the struct bootinfo' passed by the 1995-01-25 20:05:03 +00:00
resource.h #Include <sys/types.h> so that <sys/resource.h> can be #included without 1995-01-21 14:58:25 +00:00
resourcevar.h Declare fuswintr() and suswintr() the same as fusword() and susword(). 1994-11-14 14:09:38 +00:00
rlist.h Got rid of map.h. It's a leftover from the rmap code, and we use rlists. 1994-10-09 07:35:18 +00:00
rtprio.h "idle priority" support. Based on code from Henrik Vestergaard Draboel, 1994-10-02 04:48:21 +00:00
scsiio.h Added "change address" ioctl for ssc device. 1995-01-08 13:39:46 +00:00
select.h Added $Id$ 1994-08-02 07:55:43 +00:00
selinfo.h Added $Id$ 1994-08-02 07:55:43 +00:00
sem.h Got rid of compiler warnings. 1994-09-17 13:24:29 +00:00
shm.h Prototypes, prototypes and even more prototypes. Not quite done yet, but 1994-10-02 17:25:04 +00:00
signal.h Correct a name of one structure member in the sigaltstack structure. 1995-01-29 01:19:25 +00:00
signalvar.h Prototypes, prototypes and even more prototypes. Not quite done yet, but 1994-10-02 17:25:04 +00:00
snoop.h same 1995-02-27 19:47:53 +00:00
socket.h Merge in the socket-level support for Transaction TCP from the OLAH_TTCP 1995-02-07 02:01:57 +00:00
socketvar.h Prototypes, prototypes and even more prototypes. Not quite done yet, but 1994-10-02 17:25:04 +00:00
sockio.h Add generic part of generic multiple-physical-interface support (the 1994-12-21 22:57:05 +00:00
soundcard.h Remove redundant IORW definition.. 1995-03-08 18:43:49 +00:00
stat.h Prototypes, prototypes and even more prototypes. Not quite done yet, but 1994-10-02 17:25:04 +00:00
syscall-hide.h Removed obsolete vtrace() remnants. 1995-03-04 03:24:45 +00:00
syscall.h Removed obsolete vtrace() remnants. 1995-03-04 03:24:45 +00:00
sysctl.h Implement maxprocperuid and maxfilesperproc. They are tunable 1995-02-20 19:42:42 +00:00
sysent.h First attempt to run linux binaries. This is only the changes needed to 1995-02-14 19:23:22 +00:00
syslimits.h Make CHILD_MAX and OPEN_MAX a tunable parameter. 1994-12-03 17:36:37 +00:00
syslog.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
systm.h YFfix. 1995-02-14 06:15:25 +00:00
tablet.h Added $Id$ 1994-08-02 07:55:43 +00:00
termios.h Added $Id$ 1994-08-02 07:55:43 +00:00
time.h Cosmetics. (sort of) Added 19 prototypes. 1994-10-10 00:58:36 +00:00
timeb.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
times.h Added $Id$ 1994-08-02 07:55:43 +00:00
timetc.h Cosmetics. (sort of) Added 19 prototypes. 1994-10-10 00:58:36 +00:00
timex.h Redo Kernel NTP PLL support, kernel side. 1994-09-18 20:40:01 +00:00
tprintf.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
trace.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
tty.h Incorporate bde's code-review comments. 1995-02-28 00:21:11 +00:00
ttychars.h remove unnecessary occurrence of 1994-08-22 19:34:03 +00:00
ttycom.h Fight against hanging modems: add timeout to ttywait. 1995-01-05 00:01:07 +00:00
ttydefaults.h The new ld has apparently uncovered the bug that sio.c and tty.c 1995-03-06 02:50:49 +00:00
ttydev.h Bring back our support for 57K and 115K. 1994-08-26 12:07:31 +00:00
types.h Extended minor number to include bits 16-31. It was done this way rather 1994-09-25 15:56:25 +00:00
ucred.h Added prototypes here and there. Moved pfctlinput into socket.h. 1994-10-08 22:23:00 +00:00
uio.h Add some prototypes. 1994-09-15 20:24:29 +00:00
un.h Prototypes, prototypes and even more prototypes. Not quite done yet, but 1994-10-02 17:25:04 +00:00
unistd.h Added $Id$ 1994-08-02 07:55:43 +00:00
unpcb.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
user.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
utsname.h Added $Id$ 1994-08-02 07:55:43 +00:00
vadvise.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
vcmd.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
vlimit.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
vmmeter.h Added v_interrupt_free_min to cnt struct. 1995-02-22 18:06:49 +00:00
vnioctl.h ioctl definitions for the vn driver. 1994-12-04 20:09:16 +00:00
vnode.h Added a new flag "VAGE" to indicate that the vnode should go on the head 1995-03-07 19:00:47 +00:00
vsio.h Made them all idempotent. 1994-08-21 04:42:17 +00:00
wait.h Made them all idempotent. 1994-08-21 04:42:17 +00:00