Re: [PATCH] x86/nospec: Fixup array_index_nospec_mask() asm constraint

From: Linus Torvalds
Date: Tue Feb 06 2018 - 20:50:27 EST


On Tue, Feb 6, 2018 at 5:33 PM, Dan Williams <dan.j.williams@xxxxxxxxx> wrote:
> Allow the compiler to handle @size as an immediate value rather than
> allocating a register.

Actually, maybe that "ir" should be "g".

Because it's fine if it's a memory location too. "cmp" takes pretty
much anything, as long as the thing we compare _to_ is a register.

Linus