From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753806AbcHQHN5 (ORCPT ); Wed, 17 Aug 2016 03:13:57 -0400 Received: from aserp1040.oracle.com ([141.146.126.69]:50802 "EHLO aserp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753614AbcHQHN4 (ORCPT ); Wed, 17 Aug 2016 03:13:56 -0400 From: aruna.ramakrishna@oracle.com Subject: Re: [PATCH v2] mm/slab: Improve performance of gathering slabinfo stats To: Christoph Lameter , Joonsoo Kim References: <1470337273-6700-1-git-send-email-aruna.ramakrishna@oracle.com> <20160816030314.GB16913@js1304-P5Q-DELUXE> Cc: Linux Memory Management List , LKML , Mike Kravetz , Pekka Enberg , David Rientjes , Andrew Morton Organization: Oracle Corporation Message-ID: <57B40EA5.9040600@oracle.com> Date: Wed, 17 Aug 2016 00:13:41 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Source-IP: aserv0022.oracle.com [141.146.126.234] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 08/16/2016 08:52 AM, Christoph Lameter wrote: > > On Tue, 16 Aug 2016, Joonsoo Kim wrote: > >> In SLUB, nr_slabs is manipulated without holding a lock so atomic >> operation should be used. > > It could be moved under the node lock. > Christoph, Joonsoo, I agree that nr_slabs could be common between SLAB and SLUB, but I think that should be a separate patch, since converting nr_slabs to unsigned long for SLUB will cause quite a bit of change in mm/slub.c that is not related to adding counters to SLAB. I'll send out an updated slab counters patch with Joonsoo's suggested fix tomorrow (nr_slabs will be unsigned long for SLAB only, and there will be a separate definition for SLUB), and once that's in, I'll create a new patch that makes nr_slabs common for SLAB and SLUB, and also converts total_objects to unsigned long. Maybe it can include some more cleanup too. Does that sound acceptable? Thanks, Aruna