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 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-io0-f199.google.com (mail-io0-f199.google.com [209.85.223.199]) by kanga.kvack.org (Postfix) with ESMTP id 8F86C6B0038 for ; Wed, 17 Aug 2016 03:13:51 -0400 (EDT) Received: by mail-io0-f199.google.com with SMTP id m130so276654112ioa.1 for ; Wed, 17 Aug 2016 00:13:51 -0700 (PDT) Received: from aserp1040.oracle.com (aserp1040.oracle.com. [141.146.126.69]) by mx.google.com with ESMTPS id 193si10894148itq.42.2016.08.17.00.13.50 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Aug 2016 00:13:50 -0700 (PDT) From: aruna.ramakrishna@oracle.com Subject: Re: [PATCH v2] mm/slab: Improve performance of gathering slabinfo stats References: <1470337273-6700-1-git-send-email-aruna.ramakrishna@oracle.com> <20160816030314.GB16913@js1304-P5Q-DELUXE> Message-ID: <57B40EA5.9040600@oracle.com> Date: Wed, 17 Aug 2016 00:13:41 -0700 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: owner-linux-mm@kvack.org List-ID: To: Christoph Lameter , Joonsoo Kim Cc: Linux Memory Management List , LKML , Mike Kravetz , Pekka Enberg , David Rientjes , Andrew Morton 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 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org