Received: by 10.223.185.116 with SMTP id b49csp1032004wrg; Fri, 16 Feb 2018 11:09:04 -0800 (PST) X-Google-Smtp-Source: AH8x227xkpy40PdvaH4PrvT7XrVHeV1VxkCw7qaqWpUWk3yLR+p3knqw6+jLlM9becjRIMewbfBC X-Received: by 10.99.120.193 with SMTP id t184mr6037739pgc.348.1518808144811; Fri, 16 Feb 2018 11:09:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518808144; cv=none; d=google.com; s=arc-20160816; b=ARXFDPNWyWAsjiNdMZlNhVKNDplruxKgrLybRTWUGVLaeub3VZIbr2X1N5aEWc0kHZ T09QXaGbKYej1+nx9ahllk82KD5SyjJLW6wWPGcrUUt2YrZpuuOvulSN4yS9lt8e0qAx FCqVe8fr+6nYYlrRzjR/ju6+iIfXGxXBEgeU6rPJb/MIA1B1tVvOjJcX8uKs6Vejb2E6 Qeo+9uh2MGdLv2bRYZjzo/srAp0hlLq9bKvb95RfE0/SsaeZHW40Z7VHfEgM0r0S2eNi 7AGiNo59L00Tqs2SFnZGQn2PIDkao6v2B0qcV/HVDdopZeV5C83OWVC3nun+476+OeVD d4gQ== 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:dmarc-filter:arc-authentication-results; bh=wy3Ul34eOMNAYUtCzauFzF/Rb5dGZwJELLg+GoXV6Ow=; b=POMr/jIvVnt0C/RCjn/waGdOY2DSt02QlX29Mr+96nlKkar3ohw7FdTfDFvxlctsvl LawmnBT1e38vRQEXi8i2ULrWV+v9wm0n/A0A7oUu/DbUhUhtf4V1sQR0/WX/+FYathN+ V9tp+Lvctto/7CNnscfTZdhurdM6sjkBKyIVtSDFe5KLJxa5gYWe4WFxKbDKFdDjQ7qy /pY9XxoCbDLfryFh6fHoD60IyOF4kbYMjUKAYJalJdmRUc2K/Oy85UtZJqj8PkGjZXmY t7FyO7pvUFCVIQEjVjTo0fVCk8tnPN6q0SSsUfkX2V1MqP0c6JfwibPkSqlI2wBKoF0u LUTQ== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e6si5528838pgt.274.2018.02.16.11.08.50; Fri, 16 Feb 2018 11:09:04 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030576AbeBPNSU (ORCPT + 99 others); Fri, 16 Feb 2018 08:18:20 -0500 Received: from mail.kernel.org ([198.145.29.99]:58536 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1030435AbeBPNST (ORCPT ); Fri, 16 Feb 2018 08:18:19 -0500 Received: from jouet.infradead.org (unknown [179.97.41.186]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 62FBF21726; Fri, 16 Feb 2018 13:18:18 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 62FBF21726 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=acme@kernel.org Received: by jouet.infradead.org (Postfix, from userid 1000) id 929C01450DD; Fri, 16 Feb 2018 10:18:15 -0300 (-03) Date: Fri, 16 Feb 2018 10:18:15 -0300 From: Arnaldo Carvalho de Melo To: ufo19890607 Cc: peterz@infradead.org, mingo@redhat.com, alexander.shishkin@linux.intel.com, jolsa@kernel.org, dsahern@gmail.com, namhyung@kernel.org, milian.wolff@kdab.com, arnaldo.melo@gmail.com, yuzhoujian@didichuxing.com, adrian.hunter@intel.com, wangnan0@huawei.com, Kan.liang@intel.com, linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org, acme@redhat.com Subject: Re: [PATCH v4 2/2] perf stat: Add support to print counts after a period of time Message-ID: <20180216131815.GB24436@kernel.org> References: <1517217923-8302-1-git-send-email-ufo19890607@gmail.com> <1517217923-8302-3-git-send-email-ufo19890607@gmail.com> <20180215133921.GC22818@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180215133921.GC22818@kernel.org> X-Url: http://acmel.wordpress.com User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Thu, Feb 15, 2018 at 10:39:21AM -0300, Arnaldo Carvalho de Melo escreveu: > Em Mon, Jan 29, 2018 at 10:25:23AM +0100, ufo19890607 escreveu: > > From: yuzhoujian > > > > Introduce a new option to print counts after N milliseconds > > This doesn't just print counts after N ms, it _stops_ the workload after > that time _and_ prints the counts, right? > > Can you please send a followup patch fixing the description and > documentation? > > I've applied this already, but clarifying what this option does is in > demand. So, this fails to build on centos:5 and centos:6 and similar systems where the use of 'time' for a variable name breaks the build: CC /tmp/build/perf/builtin-stat.o cc1: warnings being treated as errors builtin-stat.c: In function '__run_perf_stat': builtin-stat.c:576: warning: declaration of 'time' shadows a global declaration /usr/include/time.h:187: warning: shadowed declaration is here builtin-stat.c: In function 'cmd_stat': builtin-stat.c:2710: warning: declaration of 'time' shadows a global declaration /usr/include/time.h:187: warning: shadowed declaration is here mv: cannot stat `/tmp/build/perf/.builtin-stat.o.tmp': No such file or directory make[3]: *** [/tmp/build/perf/builtin-stat.o] Error 1 make[3]: *** Waiting for unfinished jobs.... MKDIR /tmp/build/perf/util/ CC /tmp/build/perf/util/evsel_fprintf.o make[2]: *** [/tmp/build/perf/perf-in.o] Error 2 make[2]: *** Waiting for unfinished jobs.... So since I had to rename that I replaced it with 'timeout', so that it gets clear that when you specify this option you are setting a timeout period that if hit will stop the 'perf stat' session and then print the specified counters. Please let us know if you have any strong objection to this, - Arnaldo