DPDK patches and discussions
 help / color / mirror / Atom feed
From: David Marchand <david.marchand@redhat.com>
To: Jerin Jacob <jerinjacobk@gmail.com>
Cc: Thinh Tran <thinhtr@linux.vnet.ibm.com>, dpdk-dev <dev@dpdk.org>,
	 David Christensen <drc@linux.vnet.ibm.com>
Subject: Re: [dpdk-dev] [PATCH] rte_trace: fix build on PPC64
Date: Tue, 28 Apr 2020 10:52:02 +0200	[thread overview]
Message-ID: <CAJFAV8yJJkggr2bX7J5r-zmkMu4zyOhLKmtBsbS0g2o0G3ZRNA@mail.gmail.com> (raw)
In-Reply-To: <CALBAE1PxKsoVYmfN+-KKAuXsa6qZmO7rasjw2ATcqEkPzZE-_g@mail.gmail.com>

On Tue, Apr 28, 2020 at 9:58 AM Jerin Jacob <jerinjacobk@gmail.com> wrote:
>
> On Tue, Apr 28, 2020 at 3:29 AM Thinh Tran <thinhtr@linux.vnet.ibm.com> wrote:
> >
> > The AltiVec header file breaks boolean type:
> >
> > In file included from ../lib/librte_mempool/rte_mempool_trace_fp.h:18:0,
> >                  from ../lib/librte_mempool/rte_mempool.h:54,
> >                  from ../lib/librte_mbuf/rte_mbuf.h:38,
> >                  from ../lib/librte_net/rte_ether.h:23,
> >                  from ../drivers/common/mlx5/mlx5_nl.h:10,
> >                  from ../drivers/common/mlx5/mlx5_nl.c:23:
> > ../lib/librte_eal/include/rte_trace_point.h: In function
> > ‘__rte_trace_point_fp_is_enabled’:
> > ../lib/librte_eal/include/rte_trace_point.h:226:9: error: incompatible
> > types when returning type ‘int’ but ‘__vector __bool int {aka
> > __vector(4) __bool int}’ was expected
> >   return false;
> >
> > This is the same as
> >  https://git.dpdk.org/dpdk/commit/?id=725f5dd
> >
> > and yet, there is no better solution for it
> >
> > Signed-off-by: Thinh Tran <thinhtr@linux.vnet.ibm.com>
> > ---
> >  lib/librte_eal/include/rte_trace_point.h | 6 ++++++
> >  1 file changed, 6 insertions(+)
> >
> > diff --git a/lib/librte_eal/include/rte_trace_point.h b/lib/librte_eal/include/rte_trace_point.h
> > index 4d956ec16..2ede9e3ba 100644
> > --- a/lib/librte_eal/include/rte_trace_point.h
> > +++ b/lib/librte_eal/include/rte_trace_point.h
> > @@ -26,6 +26,12 @@ extern "C" {
> >  #include <rte_common.h>
> >  #include <rte_compat.h>
> >
> > +#if defined(__PPC64__) && !defined(__APPLE_ALTIVEC__)
> > +#undef bool
> > +/* redefine as in stdbool.h */
> > +#define bool _Bool
> > +#endif
>
> NACK.
>
> Please move the fix to rte_common.h or similar as it not specific to trace.
> if you do so, the following hack also not need.
> https://git.dpdk.org/dpdk/commit/?id=725f5dd

+1

-- 
David Marchand


  reply	other threads:[~2020-04-28  8:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-27 21:58 Thinh Tran
2020-04-28  7:57 ` Jerin Jacob
2020-04-28  8:52   ` David Marchand [this message]
2020-04-28 15:01   ` Thinh Tran
2020-04-28 15:04     ` David Marchand
2020-04-28 15:26       ` Thinh Tran

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=CAJFAV8yJJkggr2bX7J5r-zmkMu4zyOhLKmtBsbS0g2o0G3ZRNA@mail.gmail.com \
    --to=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=drc@linux.vnet.ibm.com \
    --cc=jerinjacobk@gmail.com \
    --cc=thinhtr@linux.vnet.ibm.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).