git: tmpfs - Fix periodic syncer cpu-bound stalls w/tmpfs on big-mem boxes

Matthew Dillon dillon at crater.dragonflybsd.org
Tue Jan 15 14:24:16 PST 2019


commit d883c473b2887a2c27549ef36e8a20c3e8ed71fd
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Tue Jan 15 14:17:26 2019 -0800

    tmpfs - Fix periodic syncer cpu-bound stalls w/tmpfs on big-mem boxes
    
    * A bug in tmpfs leaves dirty tmpfs vnodes (which is basically all
      of them) on the syncer list, causing the syncer to scan the entire
      list every few seconds.  When a large number of vnodes are involved,
      this can lead to noticable cpu-bound stalls on the cpu the syncer is
      running on.
    
    * Generally speaking this should significantly improve applications
      which use tmpfs a lot, such as synth runs, but was probably not noticed
      on machines with less than 32GB of ram due to the lower kern.maxvnodes
      default.
    
    * Solved by unconditionally removing the vnode from the syncer list
      in tmpfs_fsync(), but otherwise leaving the vnode marked VISDIRTY and
      usually also VOBJDIRTY.  Tmpfs's reclaim code properly handles the
      disconnect regardless of the syncer state of the vnode.
    
      Removing the vnode ensures that only one syncer pass is performed on
      it, instead of repeated passes every few seconds.

Summary of changes:
 sys/vfs/tmpfs/tmpfs_vnops.c | 7 +++++++
 1 file changed, 7 insertions(+)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/d883c473b2887a2c27549ef36e8a20c3e8ed71fd


-- 
DragonFly BSD source repository



More information about the Commits mailing list