[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180111142608.GF16655@krava>
Date: Thu, 11 Jan 2018 15:26:08 +0100
From: Jiri Olsa <jolsa@...hat.com>
To: kan.liang@...el.com
Cc: acme@...nel.org, peterz@...radead.org, mingo@...hat.com,
linux-kernel@...r.kernel.org, wangnan0@...wei.com,
jolsa@...nel.org, namhyung@...nel.org, ak@...ux.intel.com,
yao.jin@...ux.intel.com
Subject: Re: [PATCH V3 11/12] perf top: switch default mode to overwrite mode
On Thu, Dec 21, 2017 at 10:08:53AM -0800, kan.liang@...el.com wrote:
SNIP
> .max_stack = sysctl_perf_event_max_stack,
> .sym_pcnt_filter = 5,
> diff --git a/tools/perf/ui/browsers/hists.c b/tools/perf/ui/browsers/hists.c
> index 68146f4..56023e4 100644
> --- a/tools/perf/ui/browsers/hists.c
> +++ b/tools/perf/ui/browsers/hists.c
> @@ -638,8 +638,13 @@ int hist_browser__run(struct hist_browser *browser, const char *help)
> nr_entries = hist_browser__nr_entries(browser);
> ui_browser__update_nr_entries(&browser->b, nr_entries);
>
> - if (browser->hists->stats.nr_lost_warned !=
> - browser->hists->stats.nr_events[PERF_RECORD_LOST]) {
> + /*
> + * Don't print lost events warning for perf top,
> + * because it is overwrite mode.
> + * Perf top is the only tool which has hbt timer.
> + */
I hate that warning, but still should it be ommited only for overwrite case?
also please separate this change from the rest of the patch
jirka
> + if ((browser->hists->stats.nr_lost_warned !=
> + browser->hists->stats.nr_events[PERF_RECORD_LOST]) && !hbt) {
> browser->hists->stats.nr_lost_warned =
> browser->hists->stats.nr_events[PERF_RECORD_LOST];
> ui_browser__warn_lost_events(&browser->b);
> @@ -3203,7 +3208,8 @@ static int perf_evsel_menu__run(struct perf_evsel_menu *menu,
> case K_TIMER:
> hbt->timer(hbt->arg);
>
> - if (!menu->lost_events_warned && menu->lost_events) {
> + if (!menu->lost_events_warned &&
> + menu->lost_events && !hbt) {
> ui_browser__warn_lost_events(&menu->b);
> menu->lost_events_warned = true;
> }
> --
> 2.5.5
>
Powered by blists - more mailing lists