Linux DTrace development list
 help / color / mirror / Atom feed
From: Kris Van Hees <kris.van.hees@oracle.com>
To: Nick Alcock <nick.alcock@oracle.com>
Cc: dtrace@lists.linux.dev, dtrace-devel@oss.oracle.com
Subject: Re: [PATCH 2/2] drti: do not compile with LTO
Date: Thu, 16 Jan 2025 17:24:44 -0500	[thread overview]
Message-ID: <Z4mHLMzMMQpKKAkN@oracle.com> (raw)
In-Reply-To: <20250116215418.417155-2-nick.alcock@oracle.com>

On Thu, Jan 16, 2025 at 09:54:18PM +0000, Nick Alcock wrote:
> drti.o is shipped as object code and can be reused by many compiler
> versions: we must not put LTO IR into it.
> 
> Signed-off-by: Nick Alcock <nick.alcock@oracle.com>

Reviewed-by: Kris Van Hees <kris.van.hees@oracle.com>

> ---
>  libdtrace/Build | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/libdtrace/Build b/libdtrace/Build
> index 722351591aaea..307d7e8bf6434 100644
> --- a/libdtrace/Build
> +++ b/libdtrace/Build
> @@ -122,6 +122,10 @@ dt_prov_uprobe.c_CFLAGS := -Wno-pedantic
>  dt_debug.c_CFLAGS := -Wno-prio-ctor-dtor
>  drti.c_CFLAGS := -Wno-prio-ctor-dtor
>  
> +# drti is shipped as an object file, so do not ever generate
> +# LTO for it, since that is compiler-version-specific.
> +drti.c_CFLAGS += -fno-lto
> +
>  SHORTKERNELS := $(foreach kernel,$(KERNELS),$(shell printf %s $(kernel) | sed -e 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*$$/\1.\2.\3/'))
>  
>  -include libdtrace/$(ARCHINC)/Build
> -- 
> 2.47.1.279.g84c5f4e78e
> 

  reply	other threads:[~2025-01-16 22:24 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-16 21:54 [PATCH 1/2] tests: do not pass -flto to the compiler or linker Nick Alcock
2025-01-16 21:54 ` [PATCH 2/2] drti: do not compile with LTO Nick Alcock
2025-01-16 22:24   ` Kris Van Hees [this message]
2025-01-16 22:22 ` [PATCH 1/2] tests: do not pass -flto to the compiler or linker Kris Van Hees

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=Z4mHLMzMMQpKKAkN@oracle.com \
    --to=kris.van.hees@oracle.com \
    --cc=dtrace-devel@oss.oracle.com \
    --cc=dtrace@lists.linux.dev \
    --cc=nick.alcock@oracle.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