[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250429091742.GF4198@noisy.programming.kicks-ass.net>
Date: Tue, 29 Apr 2025 11:17:42 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Bill Wendling <morbo@...gle.com>, Nathan Chancellor <nathan@...nel.org>,
Josh Poimboeuf <jpoimboe@...nel.org>,
Harry Wentland <harry.wentland@....com>,
Leo Li <sunpeng.li@....com>,
Alex Deucher <alexander.deucher@....com>,
Christian König <christian.koenig@....com>,
David Airlie <airlied@...il.com>, Simona Vetter <simona@...ll.ch>,
Nick Desaulniers <nick.desaulniers+lkml@...il.com>,
Justin Stitt <justinstitt@...gle.com>,
the arch/x86 maintainers <x86@...nel.org>,
dri-devel <dri-devel@...ts.freedesktop.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
llvm@...ts.linux.dev
Subject: Re: clang and drm issue: objtool warnings from clang build
On Mon, Apr 28, 2025 at 12:34:27PM -0700, Linus Torvalds wrote:
> And yes, this really is a very potential and real security issue. In
> the kernel I don't think we have this ever happening, partly because a
> lot of configurations use gcc which afaik doesn't have this particular
> horrendous model of UD.
I see more and more people use clang, in a large part because of Rust.
Anyway, I've seen clang pull this stop-codegen-on-UB trick before (link
was upstream in the thread) and yes, it is horrific crap. At the time I
proposed emitting at the very least a UD2 instruction rather than just
straight up stopping code gen, but I think your proposal for a code-gen
knob to just not do this 'optimisation' at all is much better.
Powered by blists - more mailing lists