DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas.monjalon@6wind.com>
To: dev@dpdk.org
Cc: Olivier MATZ <olivier.matz@6wind.com>,
	Damjan Marion <damarion@cisco.com>
Subject: Re: [dpdk-dev] [PATCH] eal/x86: fix clang build with -O0
Date: Fri, 03 Jun 2016 10:46:44 +0200	[thread overview]
Message-ID: <21865506.clYb8lqSiq@xps13> (raw)
In-Reply-To: <57513CE3.60506@6wind.com>

2016-06-03 10:16, Olivier MATZ:
> On 06/03/2016 10:15 AM, Thomas Monjalon wrote:
> > From: Damjan Marion <damarion@cisco.com>
> > 
> > Clang seems to have a bug with asm inside inline function rte_xabort():
> > 
> > rte_rtm.h:56:15: error: invalid operand for inline asm constraint 'i'
> >         asm volatile(".byte 0xc6,0xf8,%P0" :: "i" (status) : "memory");
> >                      ^
> > 
> > It is seen only when building with EXTRA_CFLAGS=-O0.
> > 
> > The workaround is to replace the inline function by a macro.
> > 
> > Fixes: ba7468997ea6 ("spinlock: add HTM lock elision for x86")
> > 
> > Signed-off-by: Damjan Marion <damarion@cisco.com>
> > Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
> 
> Generally speaking, it's not a good idea to replace a static inline by a
> macro because it relaxes type checking. Looks ok in that case to
> workaround the clang issue.
> 
> Acked-by: Olivier Matz <olivier.matz@6wind.com>

Thanks,
This patch has been appplied very quickly for the purpose of a live demo
at a VPP event: https://wiki.fd.io/view/Events

      reply	other threads:[~2016-06-03  8:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-03  8:15 Thomas Monjalon
2016-06-03  8:16 ` Olivier MATZ
2016-06-03  8:46   ` Thomas Monjalon [this message]

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=21865506.clYb8lqSiq@xps13 \
    --to=thomas.monjalon@6wind.com \
    --cc=damarion@cisco.com \
    --cc=dev@dpdk.org \
    --cc=olivier.matz@6wind.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).