From: "Pathan, Arshiya Hayatkhan" <arshiya.hayatkhan.pathan@intel.com>
To: "Moger, Babu" <Babu.Moger@amd.com>,
"Yu, Fenghua" <fenghua.yu@intel.com>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, "H Peter Anvin" <hpa@zytor.com>,
"Luck, Tony" <tony.luck@intel.com>,
"Peter Zijlstra" <peterz@infradead.org>,
"Chatre, Reinette" <reinette.chatre@intel.com>,
James Morse <james.morse@arm.com>,
"Shankar, Ravi V" <ravi.v.shankar@intel.com>,
"Prakhya, Sai Praneeth" <sai.praneeth.prakhya@intel.com>
Cc: linux-kernel <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH v3 4/8] selftests/resctrl: Add callback to start a benchmark
Date: Wed, 21 Nov 2018 23:52:39 +0000 [thread overview]
Message-ID: <A452FAC4F7CA284ABAC2C8FAB7160B2F3239AF@ORSMSX115.amr.corp.intel.com> (raw)
In-Reply-To: <0634d990-d25c-49a9-a1ae-ad7cded35fce@amd.com>
> > +static int
> > +measure_vals(struct resctrl_val_param *param, unsigned long
> > +*bw_resc_start) {
> > + unsigned long bw_imc, bw_resc, bw_resc_end;
> > + int ret;
> > +
> > + /*
> > + * Measure memory bandwidth from resctrl and from
> > + * another source which is perf imc value or could
> > + * be something else if perf imc event is not available.
> > + * Compare the two values to validate resctrl value.
> > + * It takes 1sec to measure the data.
> > + */
> > + bw_imc = get_mem_bw_imc(param->cpu_no, param->bw_report);
> > + if (bw_imc < 0)
>
> I think this condition should be "<=". If the value is zero, it should exit.
Yes, it should be changed. Will fix it in next version.
>
> > + return bw_imc;
> > +
> > + bw_resc_end = get_mem_bw_resctrl();
> > + if (bw_resc_end < 0)
>
> I am not very sure about this. Please check if it should be "<=" 0.
This one should also be changed. Will fix it too.
>
> > + return bw_resc_end;
> > +
> > + bw_resc = (bw_resc_end - *bw_resc_start) / MB;
> > + ret = print_results_bw(param->filename, bm_pid, bw_imc, bw_resc);
> > + if (ret)
> > + return ret;
> > +
> > + *bw_resc_start = bw_resc_end;
> > +
> > + return 0;
> > +}
Thanks and Regards,
Arshiya
next prev parent reply other threads:[~2018-11-21 23:52 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-31 21:02 [PATCH v3 0/8] selftests/resctrl: Add resctrl selftest Fenghua Yu
2018-10-31 21:02 ` [PATCH v3 1/8] selftests/resctrl: Add README for resctrl tests Fenghua Yu
2018-11-01 0:50 ` Randy Dunlap
2018-10-31 21:02 ` [PATCH v3 2/8] selftests/resctrl: Add basic resctrl file system operations and data Fenghua Yu
2018-10-31 21:02 ` [PATCH v3 3/8] selftests/resctrl: Read memory bandwidth from perf IMC counter and from resctrl file system Fenghua Yu
2018-11-12 21:15 ` Moger, Babu
2018-11-21 23:48 ` Pathan, Arshiya Hayatkhan
2018-10-31 21:02 ` [PATCH v3 4/8] selftests/resctrl: Add callback to start a benchmark Fenghua Yu
2018-11-12 21:13 ` Moger, Babu
2018-11-21 23:52 ` Pathan, Arshiya Hayatkhan [this message]
2018-10-31 21:02 ` [PATCH v3 5/8] selftests/resctrl: Add built in benchmark Fenghua Yu
2018-10-31 21:02 ` [PATCH v3 6/8] selftests/resctrl: Add MBM test Fenghua Yu
2018-10-31 21:02 ` [PATCH v3 7/8] selftests/resctrl: Add MBA test Fenghua Yu
2018-10-31 21:02 ` [PATCH v3 8/8] selftests/resctrl: Add the test in MAINTAINERS Fenghua Yu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=A452FAC4F7CA284ABAC2C8FAB7160B2F3239AF@ORSMSX115.amr.corp.intel.com \
--to=arshiya.hayatkhan.pathan@intel.com \
--cc=Babu.Moger@amd.com \
--cc=fenghua.yu@intel.com \
--cc=hpa@zytor.com \
--cc=james.morse@arm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=ravi.v.shankar@intel.com \
--cc=reinette.chatre@intel.com \
--cc=sai.praneeth.prakhya@intel.com \
--cc=tglx@linutronix.de \
--cc=tony.luck@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®