From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751335AbcATF1y (ORCPT ); Wed, 20 Jan 2016 00:27:54 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:44185 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750777AbcATF1p (ORCPT ); Wed, 20 Jan 2016 00:27:45 -0500 Date: Tue, 19 Jan 2016 21:27:45 -0800 From: Andrew Morton To: Siddhesh Poyarekar Cc: Johannes Weiner , Shaohua Li , linux-mm@kvack.org, linux-kernel , kernel-team@fb.com Subject: Re: [PATCH] proc: revert /proc//maps [stack:TID] annotation Message-Id: <20160119212745.eee310f5.akpm@linux-foundation.org> In-Reply-To: References: <1453226559-17322-1-git-send-email-hannes@cmpxchg.org> <20160119141430.8ff9c464.akpm@linux-foundation.org> X-Mailer: Sylpheed 2.7.1 (GTK+ 2.18.9; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 20 Jan 2016 08:47:39 +0530 Siddhesh Poyarekar wrote: > On 20 January 2016 at 03:44, Andrew Morton wrote: > > Any thoughts on the obvious back-compatibility concerns? ie, why did > > Siddhesh implement this in the first place? My bad for not ensuring > > that the changelog told us this. > > > > https://lkml.org/lkml/2012/1/14/25 has more info: > > > > : Memory mmaped by glibc for a thread stack currently shows up as a > > : simple anonymous map, which makes it difficult to differentiate between > > : memory usage of the thread on stack and other dynamic allocation. > > : Since glibc already uses MAP_STACK to request this mapping, the > > : attached patch uses this flag to add additional VM_STACK_FLAGS to the > > : resulting vma so that the mapping is treated as a stack and not any > > : regular anonymous mapping. Also, one may use vm_flags to decide if a > > : vma is a stack. > > > > But even that doesn't really tell us what the actual *value* of the > > patch is to end-users. > > The end users needed a way to identify thread stacks programmatically > and there wasn't a way to do that. I'm afraid I no longer remember > (or have access to the resources that would aid my memory since I > changed employers) the details of their requirement. However, I did > do this on my own time because I thought it was an interesting project > for me and nobody really gave any feedback then as to its utility, so > as far as I am concerned you could roll back the main thread maps > information since the information is available in the thread-specific > files. OK, thanks. I was thinking of queueing this for 4.6 to let it bake in -next for a cycle, but quadratic performance is bad and nobody will test such an obscure feature in -next so maybe I'll jam it into 4.5 and we wait and see.