[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160708163616.GA2392@krava>
Date: Fri, 8 Jul 2016 18:36:16 +0200
From: Jiri Olsa <jolsa@...hat.com>
To: Peter Zijlstra <peterz@...radead.org>
Cc: mingo@...nel.org, acme@...nel.org, linux-kernel@...r.kernel.org,
andi@...stfloor.org, eranian@...gle.com, jolsa@...nel.org,
torvalds@...ux-foundation.org, davidcc@...gle.com,
alexander.shishkin@...ux.intel.com, namhyung@...nel.org,
kan.liang@...el.com, khandual@...ux.vnet.ibm.com
Subject: Re: [RFC][PATCH 1/7] perf/x86/intel: Rework the large PEBS setup code
On Fri, Jul 08, 2016 at 03:31:00PM +0200, Peter Zijlstra wrote:
SNIP
> /*
> - * When the event is constrained enough we can use a larger
> - * threshold and run the event with less frequent PMI.
> + * Use auto-reload if possible to save a MSR write in the PMI.
> + * This must be done in pmu::start(), because PERF_EVENT_IOC_PERIOD.
> */
> - if (hwc->flags & PERF_X86_EVENT_FREERUNNING) {
> - threshold = ds->pebs_absolute_maximum -
> - x86_pmu.max_pebs_events * x86_pmu.pebs_record_size;
> -
> - if (first_pebs)
> - perf_sched_cb_inc(event->ctx->pmu);
> - } else {
> - threshold = ds->pebs_buffer_base + x86_pmu.pebs_record_size;
> -
> - /*
> - * If not all events can use larger buffer,
> - * roll back to threshold = 1
> - */
> - if (!first_pebs &&
> - (ds->pebs_interrupt_threshold > threshold))
> - perf_sched_cb_dec(event->ctx->pmu);
> - }
hum, the original code switched back the perf_sched_cb,
in case !feerunning event was detected.. I dont see it
in the new code.. just the threshold update
jirka
Powered by blists - more mailing lists