Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754131AbbHMTuR (ORCPT ); Thu, 13 Aug 2015 15:50:17 -0400 Received: from mail-pd0-f181.google.com ([209.85.192.181]:36476 "EHLO mail-pd0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752637AbbHMTuP (ORCPT ); Thu, 13 Aug 2015 15:50:15 -0400 Date: Thu, 13 Aug 2015 12:50:13 -0700 (PDT) From: David Rientjes X-X-Sender: rientjes@chino.kir.corp.google.com To: Linus Torvalds cc: Andrew Morton , Joonsoo Kim , Al Viro , Linux Kernel Mailing List Subject: Re: get_vmalloc_info() and /proc/meminfo insanely expensive In-Reply-To: Message-ID: References: <20150812210027.88dfcf90.akpm@linux-foundation.org> User-Agent: Alpine 2.10 (DEB 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 888 Lines: 21 On Thu, 13 Aug 2015, Linus Torvalds wrote: > On Thu, Aug 13, 2015 at 11:32 AM, Linus Torvalds > wrote: > > > > Here's a totally untested patch (I'll reboot and test soon - it does > > at least compile for me). > > Seems to work for me. Anybody want to object to the admittedly disgusting patch? > Rather than a time based approach, why not invalidate when it is known to change, either on the next call to get_vmalloc_info() or as part of the vmalloc operation itself? If the numbers don't change during your test, this would seem better and I don't think any vmalloc() function is intended to be hot. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/