Re: [GIT PULL] objtool fixes

From: Josh Poimboeuf
Date: Thu Apr 03 2025 - 16:55:46 EST


On Thu, Apr 03, 2025 at 12:12:44PM -0700, Linus Torvalds wrote:
> On Thu, 3 Apr 2025 at 11:24, Josh Poimboeuf <jpoimboe@xxxxxxxxxx> wrote:
> >
> > There's also smap_save() / smap_restore(). For the latter we'd need to
> > look for alternatives with "push reg; popf", which is definitely not
> > SMAP-specific. So we'd need to start reading feature bits again, which
> > ends up even worse than what we had before.
>
> Now, I agree that smap_save / smap_restore might be worthy of an
> annotation, to show that "this is just a push/pop, but the intent is
> to save AC".
>
> Would that be ok?

Yeah, that should be fine.

If we can keep the annotations for those other alternatives, that leaves
most of the benefits of the original patch intact.

The "nop with stac/clac" alternative check does look trivial enough.

--
Josh