From owner-svn-src-head@freebsd.org Fri Apr 27 14:29:34 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4CFFAFA90A8; Fri, 27 Apr 2018 14:29:34 +0000 (UTC) (envelope-from freebsd@pdx.rh.CN85.dnsmgr.net) Received: from pdx.rh.CN85.dnsmgr.net (br1.CN84in.dnsmgr.net [69.59.192.140]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7135582536; Fri, 27 Apr 2018 14:29:33 +0000 (UTC) (envelope-from freebsd@pdx.rh.CN85.dnsmgr.net) Received: from pdx.rh.CN85.dnsmgr.net (localhost [127.0.0.1]) by pdx.rh.CN85.dnsmgr.net (8.13.3/8.13.3) with ESMTP id w3RETO5C006822; Fri, 27 Apr 2018 07:29:24 -0700 (PDT) (envelope-from freebsd@pdx.rh.CN85.dnsmgr.net) Received: (from freebsd@localhost) by pdx.rh.CN85.dnsmgr.net (8.13.3/8.13.3/Submit) id w3RETMCl006821; Fri, 27 Apr 2018 07:29:22 -0700 (PDT) (envelope-from freebsd) From: "Rodney W. Grimes" Message-Id: <201804271429.w3RETMCl006821@pdx.rh.CN85.dnsmgr.net> Subject: Re: svn commit: r333052 - head/sys/vm In-Reply-To: <201804270537.w3R5bZIl064515@repo.freebsd.org> To: Mateusz Guzik Date: Fri, 27 Apr 2018 07:29:22 -0700 (PDT) CC: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Reply-To: rgrimes@freebsd.org X-Mailer: ELM [version 2.4ME+ PL121h (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Apr 2018 14:29:34 -0000 [ Charset UTF-8 unsupported, converting... ] > Author: mjg > Date: Fri Apr 27 05:37:35 2018 > New Revision: 333052 > URL: https://svnweb.freebsd.org/changeset/base/333052 > > Log: > uma: whack main zone counter update in the slow path Remove might be a better word, whack is ambigous in this context. > Cached counters are typically zero at this point so it performs > avoidable atomics. Everything reading them also reads the cached > ones, thus there is really no point. No point in? reading them, writting them, updating them? > > Reviewed by: jeff > > Modified: > head/sys/vm/uma_core.c > > Modified: head/sys/vm/uma_core.c > ============================================================================== > --- head/sys/vm/uma_core.c Fri Apr 27 05:36:02 2018 (r333051) > +++ head/sys/vm/uma_core.c Fri Apr 27 05:37:35 2018 (r333052) > @@ -2329,14 +2329,6 @@ zalloc_start: > cpu = curcpu; > cache = &zone->uz_cpu[cpu]; > > - /* > - * Since we have locked the zone we may as well send back our stats. > - */ > - atomic_add_long(&zone->uz_allocs, cache->uc_allocs); > - atomic_add_long(&zone->uz_frees, cache->uc_frees); > - cache->uc_allocs = 0; > - cache->uc_frees = 0; > - > /* See if we lost the race to fill the cache. */ > if (cache->uc_allocbucket != NULL) { > ZONE_UNLOCK(zone); > > -- Rod Grimes rgrimes@freebsd.org