[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230324164445.GEZB3Tfe7pRV+GgE4f@fat_crate.local>
Date: Fri, 24 Mar 2023 17:44:45 +0100
From: Borislav Petkov <bp@...en8.de>
To: John Ogness <john.ogness@...utronix.de>
Cc: linux-kernel@...r.kernel.org
Subject: Re: [PATCH] x86/microcode: move @microcode_mutex definition near
usage
On Fri, Mar 24, 2023 at 05:39:35PM +0106, John Ogness wrote:
> Note that an unused mutex is being defined, even when the compiler is
> not warning about it.
Are you sure?
$ make arch/x86/kernel/cpu/microcode/core.s
grep microcode_mutex arch/x86/kernel/cpu/microcode/core.s
$
$ make CC=clang arch/x86/kernel/cpu/microcode/core.s
$ grep microcode_mutex arch/x86/kernel/cpu/microcode/core.s
$
Looks to me like it gets optimized away.
> OK, but the kernel test robots will probably beat me to it. ;-)
That's exactly the question: they haven't because this is not a new
situation. Their compilers are optimizing unused stuff away too.
:-)
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette
Powered by blists - more mailing lists