From owner-freebsd-hackers@FreeBSD.ORG Sat Jun 9 09:03:49 2012 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AD9F6106567B; Sat, 9 Jun 2012 09:03:49 +0000 (UTC) (envelope-from to.my.trociny@gmail.com) Received: from mail-wi0-f172.google.com (mail-wi0-f172.google.com [209.85.212.172]) by mx1.freebsd.org (Postfix) with ESMTP id B64FD8FC16; Sat, 9 Jun 2012 09:03:48 +0000 (UTC) Received: by wibhj8 with SMTP id hj8so1059069wib.13 for ; Sat, 09 Jun 2012 02:03:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:references:x-comment-to:sender:date:in-reply-to :message-id:user-agent:mime-version:content-type; bh=v+Nat3nuth7NIDcataR3wySj720Ci2AIkYh4h2bIdpc=; b=k1FLcdOXq7pOuUfIYr5rl7PlPGV8EQafvZc6AaoXMRICHMw09o8LtBhxlqrhK2tJJ6 VnBTpnoqZcxxDXVdbGr/17p85MjLhyQvlpkNvRhhev0/OSju7C8pX6XWXtb7tp74UCSE s4xZsE2OJeggp8993L5jnugcRZs5jthVCpPI9/ZeRCdTHaLwAykTJ82dW+TQ8qo4XNPK EgHV4YFsSAqh0On8RGMcjx19FFinfwmHuSgxTB26JjJu50gd2orm3jyv4eTqJyEI0Qwi NTcr9BCIs0Z+dBwZC5PdDqTUrhPATU38A3bGGiSGoEm8aknNJFZBDHxZmb95/co/nli7 fSCw== Received: by 10.180.83.196 with SMTP id s4mr6689670wiy.15.1339232627558; Sat, 09 Jun 2012 02:03:47 -0700 (PDT) Received: from localhost ([95.69.173.122]) by mx.google.com with ESMTPS id n6sm12099650wie.7.2012.06.09.02.03.45 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 09 Jun 2012 02:03:46 -0700 (PDT) From: Mikolaj Golub To: Konstantin Belousov References: <86sje5kkl6.fsf@kopusha.home.net> <20120609083822.GJ85127@deviant.kiev.zoral.com.ua> X-Comment-To: Konstantin Belousov Sender: Mikolaj Golub Date: Sat, 09 Jun 2012 12:03:43 +0300 In-Reply-To: <20120609083822.GJ85127@deviant.kiev.zoral.com.ua> (Konstantin Belousov's message of "Sat, 9 Jun 2012 11:38:22 +0300") Message-ID: <86obosluvk.fsf@kopusha.home.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.4 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Alan Cox , Wojciech Puchar , Robert Watson , Ivan Voras , freebsd-hackers@freebsd.org Subject: Re: SuperPages utilization survey X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 09 Jun 2012 09:03:49 -0000 On Sat, 9 Jun 2012 11:38:22 +0300 Konstantin Belousov wrote: KB> On Sat, Jun 09, 2012 at 10:31:17AM +0300, Mikolaj Golub wrote: >> >> On Fri, 1 Jun 2012 14:54:48 +0200 Ivan Voras wrote: >> >> IV> On 1 June 2012 14:35, Wojciech Puchar wrote: >> >>> http://people.freebsd.org/~ivoras/stuff/spsurvey.py >> >> ... >> >> IV> If anyone posts more data, I'll analyse it. I'm more worried about the >> IV> granularity of procstat, where it marks the entire region if a single >> IV> superpage exists in it - it means any such analysis is only >> IV> approximate. >> >> Here is a patch (for kernel and procstat) that allows to see amount of pages >> mapped to superpages. >> >> http://people.freebsd.org/~trociny/procstat-superpages.cnt.1.patch >> >> Not sure it is useful enough to be committed. KB> Superpage aggregates mappings for several normal-sized pages. KB> As a consequence, when you iterate over small pages in KB> sysctl_kern_proc_vmmap(), you account each superpage as many time as KB> much constituent small pages it contains. This is exactly what my intention was to count: how much memory are handled by superpages (using normal-sized page as a measurement unit), not amount of superpages. And I think this is what Ivan wanted to know. Do you think it is better to return number of superpages? -- Mikolaj Golub