Re: [PATCH] rust: cfi: disable function merging if CFI is enabled
Miguel Ojeda <[email protected]>
| Newsgroups | dev.linux.lists.llvm,org.kernel.vger.linux-kbuild,org.kernel.vger.linux-kernel,org.kernel.vger.rust-for-linux |
|---|---|
| Message-ID | <CANiq72m9v0V5Nnc_E1LUt24ofUUGxbRZdUC-UBz2NEbY_MA=Rg@mail.gmail.com> |
On Fri, Aug 21, 2026 at 1:43 AM Sami Tolvanen <[email protected]> wrote: > > The LLVM fix itself is trivial, and it looks like a pull request for > it already exists. I assume we'll want to drop this flag for fixed > LLVM versions when they're available. I will link it in the commit message when I pick it up soon -- already did in https://github.com/Rust-for-Linux/linux/issues/1132. I also added the `-Z` flag to https://github.com/Rust-for-Linux/linux/issues/2. The `-Zmerge-functions` flag is internal but has been there since Rust 1.34.0 in upstream commit: b91d211b4030 ("Add a target option "merge-functions" taking values in ("disabled", "trampolines", or "aliases (the default)) to allow targets to opt out of the MergeFunctions LLVM pass. Also add a corresponding -Z option with the same name and values.") so that should be fine, but I will ping upstream Rust so that they are aware we are using it. And, yeah, agreed, we probably should remove the flag conditionally later on, to confirm the bug is gone etc. Cheers, Miguel