On Tue, Oct 21, 2025 at 07:25:11PM +0200, Miguel Ojeda wrote:
On Tue, Oct 21, 2025 at 7:19 PM Peter Zijlstra peterz@infradead.org wrote:
I'll go stick it in tip/objtool/core; but I gotta ask, where are we with the toolchain support for noreturn?
Thanks Peter!
We discussed it with upstream Rust, and they understood the need, so we may get something like `--emit=noreturn` or similar, but it is still open (and not too high in the priority list since we can survive with this for now and we have other things that we really need them to get stabilized etc. But if you feel it should be prioritized more, please let me know).
Nah, as long as its not forgotten I suppose it'll show up at some point.
I would place including C headers in Rust at a *MUCH* higher priority than this. This bindgen nonsense is a giant pain in the arse.
I have the status under "Export (somehow) a list of all noreturn symbols." at:
https://github.com/Rust-for-Linux/linux/issues/355In particular, Gary proposed an alternative during those discussions:
"Gary proposed reading DWARF instead and wrote a quick Rust scriptfor it via object and gimli, though DWARF would need to be available or generated on the fly just for that (and we cannot commit a fixed list since the kernel config may change and we support several Rust versions and so on): https://gist.github.com/nbdd0121/449692570622c2f46a29ad9f47c3379a."
Right, the problem with DWARF is that you need to have DWARF and debug builds are *SLOW* :/ But perhaps rust compile times are such that that isn't noticable?