DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas.monjalon@6wind.com>
To: Michael Qiu <michael.qiu@intel.com>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH v2] lib/librte_sched: Fix compile with gcc 4.3.4
Date: Wed, 02 Dec 2015 03:18:01 +0100	[thread overview]
Message-ID: <5915028.hIVKuBcS7U@xps13> (raw)
In-Reply-To: <1449022194-25510-1-git-send-email-michael.qiu@intel.com>

2015-12-02 10:09, Michael Qiu:
> gcc 4.3.4 does not include "immintrin.h", and will post below error:
>     lib/librte_sched/rte_sched.c:56:23: error:
>     immintrin.h: No such file or directory

This compiler issue is fixed with rte_vect.h.

> To avoid this issue, a gcc version check is need and a flag to indicate
> vector ablility.

It is another issue: we need SSE2 support.

> --- a/lib/librte_sched/rte_sched.c
> +++ b/lib/librte_sched/rte_sched.c
> @@ -42,6 +42,7 @@
>  #include <rte_prefetch.h>
>  #include <rte_branch_prediction.h>
>  #include <rte_mbuf.h>
> +#include <rte_vect.h>

Shouldn't be in #ifdef RTE_SCHED_VECTOR ?

>  #include "rte_sched.h"
>  #include "rte_bitmap.h"
> @@ -53,7 +54,11 @@
>  #endif
>  
>  #ifdef RTE_SCHED_VECTOR
> -#include <immintrin.h>
> +
> +#if defined(__SSE2__)
> +#define SCHED_VECTOR_ENABLE
> +#endif

I think the flag should SCHED_VECTOR_SSE2

With this fix, the need for disabling SCHED_VECTOR for non-x86 platforms
should disappear.
But it may be safe to disable it (another patch).
Thanks

  reply	other threads:[~2015-12-02  2:19 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-26 10:49 [dpdk-dev] [PATCH] " Michael Qiu
2015-11-26 21:28 ` Thomas Monjalon
2015-11-27  2:26   ` Qiu, Michael
2015-11-27  8:59     ` Thomas Monjalon
2015-11-27 11:53       ` Qiu, Michael
2015-11-27 12:34         ` Ananyev, Konstantin
2015-11-27 14:01           ` Qiu, Michael
2015-11-27 14:09             ` Ananyev, Konstantin
2015-11-27 15:22               ` Qiu, Michael
2015-11-27 16:21                 ` Ananyev, Konstantin
2015-12-02  2:09 ` [dpdk-dev] [PATCH v2] " Michael Qiu
2015-12-02  2:18   ` Thomas Monjalon [this message]
2015-12-02  2:29     ` Qiu, Michael
2015-12-02  2:39 ` [dpdk-dev] [PATCH v3] " Michael Qiu
2015-12-02 22:10   ` 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=5915028.hIVKuBcS7U@xps13 \
    --to=thomas.monjalon@6wind.com \
    --cc=dev@dpdk.org \
    --cc=michael.qiu@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).