DPDK patches and discussions
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: Mahdi Rakhshandehroo <mahdi.rakhshandehroo@gmail.com>
Cc: dev@dpdk.org
Subject: Re: [PATCH v2] meson: add support for clang LTO
Date: Wed, 5 Jul 2023 19:55:28 -0700	[thread overview]
Message-ID: <20230705195528.38e57918@hermes.local> (raw)
In-Reply-To: <20220401045435.60172-1-mahdi.rakhshandehroo@gmail.com>

On Thu, 31 Mar 2022 21:54:35 -0700
Mahdi Rakhshandehroo <mahdi.rakhshandehroo@gmail.com> wrote:

> Currently, building DPDK with clang + LTO is unsupported, which is a
> showstopper for cross-language interprocedural optimizations. The root
> cause is that pmdinfogen expects to scan through the section headers of
> generated ELF object files, but clang's "-flto" flag generates LLVM
> bitcode instead. This patch enables LTO builds with clang, provided that
> the linker is set to lld.
> 
> The mechanism of action is clang's "-fembed-bitcode" flag, which acts
> similarly to gcc's "-ffat-lto-objects" - the compiler outputs a normal
> ELF object file that keeps pmdinfogen happy, but also embeds IR bitcode
> in a special section of the ELF that lld can then use to construct the
> final binary.
> 
> Signed-off-by: Mahdi Rakhshandehroo <mahdi.rakhshandehroo@gmail.com>
> ---

This patch still has several build failures such as Intel compiler.
Please resolve and resubmit

      reply	other threads:[~2023-07-06  2:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-01  4:54 Mahdi Rakhshandehroo
2023-07-06  2:55 ` Stephen Hemminger [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=20230705195528.38e57918@hermes.local \
    --to=stephen@networkplumber.org \
    --cc=dev@dpdk.org \
    --cc=mahdi.rakhshandehroo@gmail.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).