Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1762668Ab3DCM1u (ORCPT ); Wed, 3 Apr 2013 08:27:50 -0400 Received: from LGEMRELSE1Q.lge.com ([156.147.1.111]:48225 "EHLO LGEMRELSE1Q.lge.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1762207Ab3DCM03 (ORCPT ); Wed, 3 Apr 2013 08:26:29 -0400 X-AuditID: 9c93016f-b7c18ae000002f5f-a2-515c1ff15159 From: Namhyung Kim To: Arnaldo Carvalho de Melo Cc: Peter Zijlstra , Paul Mackerras , Ingo Molnar , Namhyung Kim , LKML , Stephane Eranian , Andi Kleen , Jiri Olsa , David Ahern Subject: [PATCH 06/10] perf hists: Move column length setting code Date: Wed, 3 Apr 2013 21:26:15 +0900 Message-Id: <1364991979-3008-7-git-send-email-namhyung@kernel.org> X-Mailer: git-send-email 1.7.11.7 In-Reply-To: <1364991979-3008-1-git-send-email-namhyung@kernel.org> References: <1364991979-3008-1-git-send-email-namhyung@kernel.org> X-Brightmail-Tracker: AAAAAA== Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1966 Lines: 49 From: Namhyung Kim They are set to constant length so no need to update every time. Cc: Stephane Eranian Signed-off-by: Namhyung Kim --- tools/perf/util/hist.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/tools/perf/util/hist.c b/tools/perf/util/hist.c index 1fb1535940f8..e144aefc76e6 100644 --- a/tools/perf/util/hist.c +++ b/tools/perf/util/hist.c @@ -56,6 +56,12 @@ void hists__reset_col_len(struct hists *hists) hists__set_col_len(hists, HISTC_ADDR, BITS_PER_LONG / 4 + 2); hists__set_col_len(hists, HISTC_ADDR_FROM, BITS_PER_LONG / 4 + 2); hists__set_col_len(hists, HISTC_ADDR_TO, BITS_PER_LONG / 4 + 2); + hists__set_col_len(hists, HISTC_LOCAL_WEIGHT, 12); + hists__set_col_len(hists, HISTC_GLOBAL_WEIGHT, 12); + hists__set_col_len(hists, HISTC_MEM_LOCKED, 6); + hists__set_col_len(hists, HISTC_MEM_TLB, 22); + hists__set_col_len(hists, HISTC_MEM_SNOOP, 12); + hists__set_col_len(hists, HISTC_MEM_LVL, 21 + 3); } static void hists__set_unres_dso_col_len(struct hists *hists, int dso) @@ -156,13 +162,6 @@ void hists__calc_col_len(struct hists *hists, struct hist_entry *h) hists__new_col_len(hists, HISTC_MEM_DADDR_SYMBOL, symlen); hists__set_unres_dso_col_len(hists, HISTC_MEM_DADDR_DSO); } - - hists__new_col_len(hists, HISTC_MEM_LOCKED, 6); - hists__new_col_len(hists, HISTC_MEM_TLB, 22); - hists__new_col_len(hists, HISTC_MEM_SNOOP, 12); - hists__new_col_len(hists, HISTC_MEM_LVL, 21 + 3); - hists__new_col_len(hists, HISTC_LOCAL_WEIGHT, 12); - hists__new_col_len(hists, HISTC_GLOBAL_WEIGHT, 12); } void hists__output_recalc_col_len(struct hists *hists, int max_rows) -- 1.7.11.7 -- 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/