From: "Sekhar, Ashwin" <Ashwin.Sekhar@cavium.com>
To: Jianbo Liu <jianbo.liu@linaro.org>
Cc: "thomas@monjalon.net" <thomas@monjalon.net>,
"cristian.dumitrescu@intel.com" <cristian.dumitrescu@intel.com>,
"Jacob, Jerin" <Jerin.JacobKollanukkaran@cavium.com>,
"dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH] sched: enable neon optimizations
Date: Fri, 28 Apr 2017 05:27:11 +0000 [thread overview]
Message-ID: <CY1PR07MB242886C62868A06C26A6D31992130@CY1PR07MB2428.namprd07.prod.outlook.com> (raw)
In-Reply-To: <CAP4Qi3_hYEFx0YfbYfeb9sTQfnogGuM0gkgGcRpSKHx+DS+uWg@mail.gmail.com>
On Friday 28 April 2017 09:20 AM, Jianbo Liu wrote:
> On 27 April 2017 at 21:00, Ashwin Sekhar T K
> <ashwin.sekhar@caviumnetworks.com> wrote:
>> * Enabled CONFIG_RTE_SCHED_VECTOR for arm64
>> * Verified the changes with sched_autotest unit test case
>>
>> Signed-off-by: Ashwin Sekhar T K <ashwin.sekhar@caviumnetworks.com>
>> ---
>> config/defconfig_arm64-armv8a-linuxapp-gcc | 2 +-
>> lib/librte_sched/rte_sched.c | 22 ++++++++++++++++++++++
>> 2 files changed, 23 insertions(+), 1 deletion(-)
>>
>> diff --git a/config/defconfig_arm64-armv8a-linuxapp-gcc b/config/defconfig_arm64-armv8a-linuxapp-gcc
>> index 65888ce..021044a 100644
>> --- a/config/defconfig_arm64-armv8a-linuxapp-gcc
>> +++ b/config/defconfig_arm64-armv8a-linuxapp-gcc
>> @@ -48,4 +48,4 @@ CONFIG_RTE_LIBRTE_FM10K_PMD=n
>> CONFIG_RTE_LIBRTE_SFC_EFX_PMD=n
>> CONFIG_RTE_LIBRTE_AVP_PMD=n
>>
>> -CONFIG_RTE_SCHED_VECTOR=n
>> +CONFIG_RTE_SCHED_VECTOR=y
>
> It's enough to remove this line only, I don't think you must enable it
> explicitly in the armv8a common config.
>
Tried removing this line from armv8a config. But in that case
RTE_SCHED_VECTOR doesn't get defined.
./config/common_base has "CONFIG_RTE_SCHED_VECTOR=n" as the default
setting. So enabling explicitly is required.
- Ashwin
>> diff --git a/lib/librte_sched/rte_sched.c b/lib/librte_sched/rte_sched.c
>> index 614705d..4ba476a 100644
>> --- a/lib/librte_sched/rte_sched.c
>> +++ b/lib/librte_sched/rte_sched.c
>> @@ -58,6 +58,8 @@
>>
>> #if defined(__SSE4__)
>> #define SCHED_VECTOR_SSE4
>> +#elif defined(RTE_MACHINE_CPUFLAG_NEON)
>> +#define SCHED_VECTOR_NEON
>> #endif
>>
>> #endif
>> @@ -1732,6 +1734,26 @@ grinder_pipe_exists(struct rte_sched_port *port, uint32_t base_pipe)
>> return 1;
>> }
>>
>> +#elif defined(SCHED_VECTOR_NEON)
>> +
>> +static inline int
>> +grinder_pipe_exists(struct rte_sched_port *port, uint32_t base_pipe)
>> +{
>> + uint32x4_t index, pipes;
>> + uint32_t *pos = (uint32_t *)port->grinder_base_bmp_pos;
>> +
>> + index = vmovq_n_u32(base_pipe);
>> + pipes = vld1q_u32(pos);
>> + if (!vminvq_u32(veorq_u32(pipes, index)))
>> + return 1;
>> +
>> + pipes = vld1q_u32(pos + 4);
>> + if (!vminvq_u32(veorq_u32(pipes, index)))
>> + return 1;
>> +
>> + return 0;
>> +}
>> +
>> #else
>>
>> static inline int
>> --
>> 2.7.4
>>
>
next prev parent reply other threads:[~2017-04-28 5:27 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-27 13:00 Ashwin Sekhar T K
2017-04-28 3:50 ` Jianbo Liu
2017-04-28 5:27 ` Sekhar, Ashwin [this message]
2017-04-28 5:37 ` Jianbo Liu
2017-04-28 6:03 ` Sekhar, Ashwin
2017-04-28 6:15 ` [dpdk-dev] [PATCH v2] sched: add " Ashwin Sekhar T K
2017-04-28 8:50 ` Jianbo Liu
2017-07-03 13:15 ` Thomas Monjalon
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=CY1PR07MB242886C62868A06C26A6D31992130@CY1PR07MB2428.namprd07.prod.outlook.com \
--to=ashwin.sekhar@cavium.com \
--cc=Jerin.JacobKollanukkaran@cavium.com \
--cc=cristian.dumitrescu@intel.com \
--cc=dev@dpdk.org \
--cc=jianbo.liu@linaro.org \
--cc=thomas@monjalon.net \
/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).