Received: by 10.223.185.116 with SMTP id b49csp4083729wrg; Tue, 6 Mar 2018 09:31:16 -0800 (PST) X-Google-Smtp-Source: AG47ELvaRLbRIiy7dLBAP11qn1GNW4uyJ1MwUG0GkTWfkq2t4xK3E3nzPaYh9UFpEmFNVZ2UB6IR X-Received: by 2002:a17:902:8c93:: with SMTP id t19-v6mr17372310plo.304.1520357475918; Tue, 06 Mar 2018 09:31:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520357475; cv=none; d=google.com; s=arc-20160816; b=f7ogpplWEAY2iPdXKjYboMP+il2W1VFjfMCp15AGjQz9vTzSkWRUsLnzKigCugqs97 8uzdLRVf8GkmTq0DHJf5gwLSOKMoexuYZhLBfydMxwnaDBn9+meQ/hTN/c9caTh7ZCZY xI3E6SNzZRj/foJIAUCLqoE/cJPEZkDBUp4qkN5dcRqcQ3zvGreA9zhv61wH4EmkbzEJ nVYXli7St9Z+v5tvMWZDU4MRDH5zkDt0G9ThZiokZ0LA1Vg9juLvvFbdF6g4iAz5PQmb 4ijXiXzS1RIWmfuhVksL/VgKSjmbIqeSkySOWLQWkiFjDqzbpE41tpbp/VZnHxBJI/Qh b9Zw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=IW1oW9QW142KiN4739M9zpxO3oaOdqPbWeW7FL9kDag=; b=x5MqKEsko5+RjwlFmZV86B7YVDasGP2B1kH3ov9Jt90wQ+/WdC77BvfskQgOFvfQMr mB7MhNFl+Tj1O8ZVmY0zNeF8iZ/k3PoOLVOT2AeJyiBp2kPV2EbQLhTxA6ewT0Am3Zz/ VEkGwvhJlnbWZ9F/1kzBmxWeHXIg+h5Wv+nNlq/ZMkyKziyaACIiAsp4833NbtFZb+DY /bTWC5EZZU14ENL2bQgeRneCFFRJiyhJ+NNhKrz//NDnPI7SYAPsfJetcdVhkH1PT5S1 qx6tw/nCxInHOx7lJb4n4OC29exH5/VsK6iDtFcu6E/ccBjIuMsWJUqAhgqKHL23bcH5 3QIA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q4-v6si11384972plb.29.2018.03.06.09.31.00; Tue, 06 Mar 2018 09:31:15 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753868AbeCFRaK (ORCPT + 99 others); Tue, 6 Mar 2018 12:30:10 -0500 Received: from mx1.redhat.com ([209.132.183.28]:34940 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752784AbeCFRaJ (ORCPT ); Tue, 6 Mar 2018 12:30:09 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 32D602BBDF3; Tue, 6 Mar 2018 17:30:09 +0000 (UTC) Received: from sandy.ghostprotocols.net (ovpn-64-2.rdu2.redhat.com [10.10.64.2]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E28F060C8A; Tue, 6 Mar 2018 17:30:08 +0000 (UTC) Received: by sandy.ghostprotocols.net (Postfix, from userid 1000) id 309E24973; Tue, 6 Mar 2018 14:30:06 -0300 (BRT) Date: Tue, 6 Mar 2018 14:30:06 -0300 From: Arnaldo Carvalho de Melo To: Andi Kleen Cc: Cong Wang , linux-kernel@vger.kernel.org, Jiri Olsa , Ilya Pronin Subject: Re: [PATCH] perf stat: fix cvs output format Message-ID: <20180306173006.GB2213@redhat.com> References: <20180306064353.31930-1-xiyou.wangcong@gmail.com> <20180306170011.GD25017@tassilo.jf.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180306170011.GD25017@tassilo.jf.intel.com> X-Url: http://acmel.wordpress.com User-Agent: Mutt/1.5.20 (2009-12-10) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Tue, 06 Mar 2018 17:30:09 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Tue, Mar 06, 2018 at 09:00:11AM -0800, Andi Kleen escreveu: > On Mon, Mar 05, 2018 at 10:43:53PM -0800, Cong Wang wrote: > > From: Ilya Pronin > > > > When printing stats in CSV mode, perf stat appends extra CSV > > separators when counter is not supported: > > > > ,,L1-dcache-store-misses,mesos/bd442f34-2b4a-47df-b966-9b281f9f56fc,0,100.00,,,, > > > > which causes a failure of parsing fields. The numbers of separators > > Causes failure in what? > > > is fixed for each line, no matter supported or not supported. > > I don't think they're extra fields, there are cases where they can be filled out My understanding was that at some place there is a if/else if (supported counters) fprintf_something with N fields, all filled in else fprintf_empty_fields with != N fields So I think this is not about using things like 'a,b,,,,,,' but about using different number of commas (fields) for supported/unsupported counters, no? - Arnaldo > for variance, metricvalue, unit. And other code in perf too uses empty > fields when something is not available. > > - optional usec time stamp in fractions of second (with -I xxx) > - optional CPU, core, or socket identifier > - optional number of logical CPUs aggregated > - counter value > - unit of the counter value or empty > - event name > - run time of counter > - percentage of measurement time the counter was running > - optional variance if multiple values are collected with -r > - optional metric value > - optional unit of metric > > > -Andi