[PATCH v2 2/2] powerpc/bug: Provide better flexibility to WARN_ON/__WARN_FLAGS() with asm goto
Segher Boessenkool
segher at kernel.crashing.org
Fri Aug 27 00:12:54 AEST 2021
On Thu, Aug 26, 2021 at 01:21:39PM +1000, Michael Ellerman wrote:
> So there seems to be some misunderstanding with clang, it doesn't like
> us passing an expression to the inline asm.
>
> AFAIK it is legal to pass expressions as inputs to inline asm, ie. it
> doesn't have to just be a variable name.
It certainly is. That is the whole point of inline asm! This way, all
of the C code "around" the asm can be optimised.
> This patch seems to fix it. Not sure if that's just papering over it though.
It is, and it makes less optimised code (also on GCC), as Christophe
points out.
Segher
More information about the Linuxppc-dev
mailing list