Date: Mon, 3 Jun 2013 17:36:44 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r251322 - head/sys/kern Message-ID: <201306031736.r53Hain5093431@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kib Date: Mon Jun 3 17:36:43 2013 New Revision: 251322 URL: http://svnweb.freebsd.org/changeset/base/251322 Log: Be more generous when donating the current thread time to the owner of the vnode lock while iterating over the free vnode list. Instead of yielding, pause for 1 tick. The change is reported to help in some virtualized environments. Submitted by: Roger Pau Monn? <roger.pau@citrix.com> Discussed with: jilles Tested by: pho MFC after: 2 weeks Modified: head/sys/kern/vfs_subr.c Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Mon Jun 3 17:36:26 2013 (r251321) +++ head/sys/kern/vfs_subr.c Mon Jun 3 17:36:43 2013 (r251322) @@ -4693,7 +4693,7 @@ restart: if (mp_ncpus == 1 || should_yield()) { TAILQ_INSERT_BEFORE(vp, *mvp, v_actfreelist); mtx_unlock(&vnode_free_list_mtx); - kern_yield(PRI_USER); + pause("vnacti", 1); mtx_lock(&vnode_free_list_mtx); goto restart; }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201306031736.r53Hain5093431>