DPDK patches and discussions
 help / color / mirror / Atom feed
From: Shally Verma <shallyv@marvell.com>
To: "Trahe, Fiona" <fiona.trahe@intel.com>,
	"Trybula, ArturX" <arturx.trybula@intel.com>,
	"dev@dpdk.org" <dev@dpdk.org>,
	"Dybkowski, AdamX" <adamx.dybkowski@intel.com>,
	"akhil.goyal@nxp.com" <akhil.goyal@nxp.com>
Subject: Re: [dpdk-dev] [EXT] [PATCH v4 1/1] app/test-compress-perf: report header improvement
Date: Wed, 17 Jul 2019 07:21:41 +0000	[thread overview]
Message-ID: <BN6PR1801MB2052109FC4F19994915CE7ABADC90@BN6PR1801MB2052.namprd18.prod.outlook.com> (raw)
In-Reply-To: <348A99DA5F5B7549AA880327E580B435897C5566@IRSMSX101.ger.corp.intel.com>



> -----Original Message-----
> From: Trahe, Fiona <fiona.trahe@intel.com>
> Sent: Tuesday, July 16, 2019 7:20 PM
> To: Trybula, ArturX <arturx.trybula@intel.com>; Shally Verma
> <shallyv@marvell.com>; dev@dpdk.org; Dybkowski, AdamX
> <adamx.dybkowski@intel.com>; akhil.goyal@nxp.com
> Cc: Trahe, Fiona <fiona.trahe@intel.com>
> Subject: RE: [EXT] [PATCH v4 1/1] app/test-compress-perf: report header
> improvement
> 
....

> >
> > > -----Original Message-----
> > > From: Artur Trybula <arturx.trybula@intel.com>
> > > Sent: Friday, July 12, 2019 4:13 PM
> > > To: dev@dpdk.org; fiona.trahe@intel.com; Shally Verma
> > > <shallyv@marvell.com>; adamx.dybkowski@intel.com;
> > > arturx.trybula@intel.com; akhil.goyal@nxp.com
> > > Subject: [EXT] [PATCH v4 1/1] app/test-compress-perf: report header
> > > improvement
> > >
> > > External Email
> > >
> > > --------------------------------------------------------------------
> > > -- This patch adds extra features to the compress performance test.
> > > Some important parameters (memory allocation, number of ops, number
> > > of
> > > segments) are calculated and printed out on the screen.
> > > Information about compression threads is also provided.
> > >
> > > Signed-off-by: Artur Trybula <arturx.trybula@intel.com>
> > > ---
> > >  .../comp_perf_test_benchmark.c                | 21 ++++-
> > >  .../comp_perf_test_common.c                   | 94 ++++++++++++++++++-
> > >  .../comp_perf_test_common.h                   |  6 ++
> > >  app/test-compress-perf/main.c                 |  4 +-
> > >  4 files changed, 120 insertions(+), 5 deletions(-)
> > >
> > > diff --git a/app/test-compress-perf/comp_perf_test_benchmark.c
> > > b/app/test-compress-perf/comp_perf_test_benchmark.c
> > > index aa1f8eea2..887459449 100644
> > > --- a/app/test-compress-perf/comp_perf_test_benchmark.c
> > > +++ b/app/test-compress-perf/comp_perf_test_benchmark.c
> > > @@ -329,9 +329,26 @@ cperf_benchmark_test_runner(void *test_ctx)
> > >  	struct comp_test_data *test_data = ctx->ver.options;
> > >  	uint32_t lcore = rte_lcore_id();
> > >  	static rte_atomic16_t display_once = RTE_ATOMIC16_INIT(0);
> > > +	int i, ret = EXIT_SUCCESS;
> > >
> > >  	ctx->ver.mem.lcore_id = lcore;
> > > -	int i, ret = EXIT_SUCCESS;
> > > +
> > > +	/*
> > > +	 * printing information about current compression thread
> > > +	 */
> > > +	if (rte_atomic16_test_and_set(&ctx->ver.mem.print_info_once))
> > Question: runner() will be executed by each core so is ctx is thread
> > local variable or global.? If it can be made thread local, then there would be
> no need of atomic here?
> > [Artur] Runners are restarted for each compression level. It's enough
> > to have the data printed only once.
> [Fiona] added clarification - we originally did as you suggest, but in cases
> where there are multiple params, e.g. level 1-9, the thread is
> started/stopped for each level, so the header was printing out many times -
> always with the same data. So we needed the atomic to resolve.
> 
[Shally] Okay. 

> >
....

> > > diff --git a/app/test-compress-perf/comp_perf_test_common.c
> > > b/app/test- compress-perf/comp_perf_test_common.c
> > > index 472c76686..3dc9349b0 100644
> > > --- a/app/test-compress-perf/comp_perf_test_common.c
> > > +++ b/app/test-compress-perf/comp_perf_test_common.c
> > > @@ -16,6 +16,18 @@
> > >
> > >  #define DIV_CEIL(a, b)  ((a) / (b) + ((a) % (b) != 0))
> > >
> > > +struct performance_tests_results {
> > > +	uint16_t total_segments;
> > > +	uint16_t segment_sz;
> > > +	uint16_t last_segment_sz;
> > > +	uint32_t total_buffs;	      /*number of buffers = number of ops*/
> > > +	uint16_t segments_per_buff;
> > > +	uint16_t segments_per_last_buff;
> > > +	size_t input_data_sz;
> > > +};
> > These looks more like test configuration than result. If you agree, then can
> rename it to test_config ..
> > [Artur] These are exactly tests results, internal variables used by the
> algorithm. A kind of snapshot.
> > Config by definition is used for configuration. In this case all the fields are
> only printed out.
> [Fiona] I can see the confusion, it's not the input config - but it's also
> confusing to call it results, as that implies the throughput and ratio numbers.
> How about cperf_buffer_info?
[Shally] this sound better.

> >
...

> > > +	if (tests_res.segments_per_last_buff > 1) {
> > > +		printf("	• 1 op %u segments:\n",
> > > +				tests_res.segments_per_last_buff);
> > > +		printf("		o %u segment size %u\n",
> > > +			tests_res.segments_per_last_buff - 1,
> > > +			tests_res.segment_sz);
> > > +		printf("		o last segment size %u\n",
> > > +			tests_res.last_segment_sz);
> > > +	} else if (tests_res.segments_per_last_buff == 1) {
> > > +		printf("	• 1 op (the last one): %u segment %u"
> > > +				" byte(s) long\n\n",
> > > +			tests_res.segments_per_last_buff,
> > > +			tests_res.last_segment_sz);
> > > +	}
> > Probably this if and else if here can be replaced by just 1 statement.
> > [Artur] I think it's ok. This version is clear. If you like I can remove {}
> brackets from the "else if".
> [Fiona] I think it's ok as is - there are different output whether >1 or ==1, so
> better to leave as separate paths.
[Shally] Okay. That was just my 2 cents. Am fine it "as is".

> >
..
> > > 2.17.1


  reply	other threads:[~2019-07-17  7:21 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-03 10:24 [dpdk-dev] [PATCH] " Artur Trybula
2019-06-26 17:04 ` Shally Verma
2019-06-27  8:58   ` Trybula, ArturX
2019-06-27 11:00     ` Shally Verma
2019-06-27 11:46       ` Trybula, ArturX
2019-06-27 14:38         ` Shally Verma
2019-06-28  9:52           ` Trybula, ArturX
2019-07-05  6:30 ` [dpdk-dev] [PATCH v2 0/1] add extra features to test-compress-perf Artur Trybula
2019-07-05  6:30   ` [dpdk-dev] [PATCH v2 1/1] app/test-compress-perf: report header improvement Artur Trybula
2019-07-05  6:53     ` Jerin Jacob Kollanukkaran
2019-07-05  7:40   ` [dpdk-dev] [PATCH v3 0/1] add extra features to test-compress-perf Artur Trybula
2019-07-05  7:40     ` [dpdk-dev] [PATCH v3 1/1] app/test-compress-perf: report header improvement Artur Trybula
2019-07-12 10:43     ` [dpdk-dev] [PATCH v4 0/1] add extra features to test-compress-perf Artur Trybula
2019-07-12 10:43       ` [dpdk-dev] [PATCH v4 1/1] app/test-compress-perf: report header improvement Artur Trybula
2019-07-15 12:47         ` [dpdk-dev] [EXT] " Shally Verma
2019-07-15 14:01           ` Trybula, ArturX
2019-07-16 13:49             ` Trahe, Fiona
2019-07-17  7:21               ` Shally Verma [this message]
2019-07-17 11:02       ` [dpdk-dev] [PATCH v5 0/1] add extra features to test-compress-perf Artur Trybula
2019-07-17 11:02         ` [dpdk-dev] [PATCH v5 1/1] app/test-compress-perf: report header improvement Artur Trybula
2019-07-17 11:15           ` [dpdk-dev] [EXT] " Shally Verma
2019-07-17 11:26             ` Trybula, ArturX
2019-07-19 13:17               ` Akhil Goyal
2019-07-19 16:21                 ` Thomas Monjalon
2019-07-19 17:37                   ` Trahe, Fiona
2019-07-24 12:53           ` [dpdk-dev] [PATCH v6 0/1] add extra features to test-compress-perf Adam Dybkowski
2019-07-24 12:53             ` [dpdk-dev] [PATCH v6 1/1] app/test-compress-perf: provide more detailed report Adam Dybkowski
2019-07-24 13:55               ` [dpdk-dev] [PATCH v7 0/1] add extra features to test-compress-perf Adam Dybkowski
2019-07-24 13:55                 ` [dpdk-dev] [PATCH v7 1/1] app/test-compress-perf: provide more detailed report Adam Dybkowski
2019-07-25 12:39                   ` Trahe, Fiona
2019-07-26 12:41                     ` Akhil Goyal
2019-07-17 11:16         ` [dpdk-dev] [EXT] [PATCH v5 0/1] add extra features to test-compress-perf Shally Verma

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=BN6PR1801MB2052109FC4F19994915CE7ABADC90@BN6PR1801MB2052.namprd18.prod.outlook.com \
    --to=shallyv@marvell.com \
    --cc=adamx.dybkowski@intel.com \
    --cc=akhil.goyal@nxp.com \
    --cc=arturx.trybula@intel.com \
    --cc=dev@dpdk.org \
    --cc=fiona.trahe@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;
as well as URLs for NNTP newsgroup(s).