From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932093AbbCaOfy (ORCPT ); Tue, 31 Mar 2015 10:35:54 -0400 Received: from mx1.redhat.com ([209.132.183.28]:42038 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754662AbbCaOfw (ORCPT ); Tue, 31 Mar 2015 10:35:52 -0400 Date: Tue, 31 Mar 2015 16:35:46 +0200 From: Jiri Olsa To: David Ahern Cc: acme@kernel.org, linux-kernel@vger.kernel.org, Don Zickus , Joe Mario Subject: Re: [PATCH v2 1/2] perf tool: Refactor comm/tgid lookup Message-ID: <20150331143546.GD31798@krava.brq.redhat.com> References: <1427747758-18510-1-git-send-email-dsahern@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1427747758-18510-1-git-send-email-dsahern@gmail.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 30, 2015 at 02:35:57PM -0600, David Ahern wrote: > Rather than parsing /proc/pid/status file one line at a time, read > it into a buffer in one shot and search for all strings in one pass. > > tgid conversion also simplified -- removing the isspace walk. As > noted by Arnaldo those are not needed for atoi == strtol calls. > > Signed-off-by: David Ahern > Cc: Don Zickus > Cc: Joe Mario > Cc: Jiri Olsa Acked-by: Jiri Olsa thanks, jirka