From: Andi Kleen
Enable metrics printing in --per-core / --per-socket mode. We need
to save the shadow metrics in a unique place. Always use the first
CPU in the aggregation. Then use the same CPU to retrieve the
shadow value later.
Example output:
% perf stat --per-core
From: Andi Kleen
Enable metrics printing in --per-core / --per-socket mode. We need
to save the shadow metrics in a unique place. Always use the first
CPU in the aggregation. Then use the same CPU to retrieve the
shadow value later.
Example output:
% perf stat --per-core -a ./BC1s
> > +
> > static void print_aggr(char *prefix)
> > {
> > FILE *output = stat_config.output;
> > @@ -982,6 +1024,8 @@ static void print_aggr(char *prefix)
> > if (!(aggr_map || aggr_get_id))
> > return;
> >
> > + aggr_update_shadow();
>
> this should be called from
> > +
> > static void print_aggr(char *prefix)
> > {
> > FILE *output = stat_config.output;
> > @@ -982,6 +1024,8 @@ static void print_aggr(char *prefix)
> > if (!(aggr_map || aggr_get_id))
> > return;
> >
> > + aggr_update_shadow();
>
> this should be called from
On Mon, Feb 22, 2016 at 05:52:02PM +0100, Andi Kleen wrote:
> On Sun, Feb 21, 2016 at 06:15:35PM +0100, Jiri Olsa wrote:
> > On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
> >
> > SNIP
> >
> > > @@ -892,7 +908,10 @@ static void printout(int id, int nr, struct
> > > perf_evsel
On Mon, Feb 22, 2016 at 05:52:02PM +0100, Andi Kleen wrote:
> On Sun, Feb 21, 2016 at 06:15:35PM +0100, Jiri Olsa wrote:
> > On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
> >
> > SNIP
> >
> > > @@ -892,7 +908,10 @@ static void printout(int id, int nr, struct
> > > perf_evsel
On Sun, Feb 21, 2016 at 06:15:35PM +0100, Jiri Olsa wrote:
> On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
>
> SNIP
>
> > @@ -892,7 +908,10 @@ static void printout(int id, int nr, struct perf_evsel
> > *counter, double uval,
> > struct perf_stat_output_ctx out;
> > struct
On Sun, Feb 21, 2016 at 06:15:35PM +0100, Jiri Olsa wrote:
> On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
>
> SNIP
>
> > @@ -892,7 +908,10 @@ static void printout(int id, int nr, struct perf_evsel
> > *counter, double uval,
> > struct perf_stat_output_ctx out;
> > struct
On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
SNIP
> @@ -892,7 +908,10 @@ static void printout(int id, int nr, struct perf_evsel
> *counter, double uval,
> struct perf_stat_output_ctx out;
> struct outstate os = {
> .fh = stat_config.output,
> -
On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
SNIP
> @@ -892,7 +908,10 @@ static void printout(int id, int nr, struct perf_evsel
> *counter, double uval,
> struct perf_stat_output_ctx out;
> struct outstate os = {
> .fh = stat_config.output,
> -
On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
SNIP
> +static void aggr_update_shadow(void)
> +{
> + int cpu, cpu2, s2, id, s;
> + u64 val;
> + struct perf_evsel *counter;
> +
> + for (s = 0; s < aggr_map->nr; s++) {
> + id = aggr_map->map[s];
> +
On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
SNIP
> +static void aggr_update_shadow(void)
> +{
> + int cpu, cpu2, s2, id, s;
> + u64 val;
> + struct perf_evsel *counter;
> +
> + for (s = 0; s < aggr_map->nr; s++) {
> + id = aggr_map->map[s];
> +
On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
SNIP
>
> perf_stat__print_shadow_stats(counter, uval,
> stat_config.aggr_mode == AGGR_GLOBAL ? 0 :
> - cpu_map__id_to_cpu(id),
> +
On Wed, Feb 17, 2016 at 02:44:02PM -0800, Andi Kleen wrote:
SNIP
>
> perf_stat__print_shadow_stats(counter, uval,
> stat_config.aggr_mode == AGGR_GLOBAL ? 0 :
> - cpu_map__id_to_cpu(id),
> +
From: Andi Kleen
Enable metrics printing in --per-core / --per-socket mode. We need
to save the shadow metrics in a unique place. Always use the first
CPU in the aggregation. Then use the same CPU to retrieve the
shadow value later.
Example output:
% perf stat --per-core
From: Andi Kleen
Enable metrics printing in --per-core / --per-socket mode. We need
to save the shadow metrics in a unique place. Always use the first
CPU in the aggregation. Then use the same CPU to retrieve the
shadow value later.
Example output:
% perf stat --per-core -a ./BC1s
16 matches
Mail list logo