[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20251124163315.GL4068168@noisy.programming.kicks-ass.net>
Date: Mon, 24 Nov 2025 17:33:15 +0100
From: Peter Zijlstra <peterz@...radead.org>
To: Miguel Ojeda <miguel.ojeda.sandonis@...il.com>
Cc: Boqun Feng <boqun.feng@...il.com>,
Stephen Rothwell <sfr@...b.auug.org.au>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...nel.org>, "H. Peter Anvin" <hpa@...or.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Linux Next Mailing List <linux-next@...r.kernel.org>,
ojeda@...nel.org, Danilo Krummrich <dakr@...nel.org>,
Alexandre Courbot <acourbot@...dia.com>,
nouveau@...ts.freedesktop.org, Alice Ryhl <aliceryhl@...gle.com>
Subject: Re: linux-next: build failure after merge of the tip tree
On Mon, Nov 24, 2025 at 03:55:44PM +0100, Peter Zijlstra wrote:
> On Mon, Nov 24, 2025 at 03:51:46PM +0100, Miguel Ojeda wrote:
> > On Mon, Nov 24, 2025 at 3:47 PM Peter Zijlstra <peterz@...radead.org> wrote:
>
> > By the way, I have had this patch around for RANDSTRUCT a long time:
> >
> > https://lore.kernel.org/rust-for-linux/20241119185747.862544-1-ojeda@kernel.org/
> >
> > More than glad if someone confirms it works for them...
>
> /me mumbles something about using clang to inject C IR into the Rust
> thing and kicking bindgen to the curb :-)
FWIW it might be relatively simple to abuse precompiled headers for
this. Generate the pch files using clang and the normal linux build
flags, then let rust do something like:
unsafe extern "C" include "header.h.pch"
or whatever fits the syntax best -- some day I'll get around to learning
this thing.
That way you can fairly trivially inject AST/IR from another language --
including all the inline functions and inline asm bits.
Powered by blists - more mailing lists