[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1521534071.20126.218.camel@infradead.org>
Date: Tue, 20 Mar 2018 08:21:11 +0000
From: David Woodhouse <dwmw2@...radead.org>
To: "H.J. Lu" <hjl.tools@...il.com>,
LKML <linux-kernel@...r.kernel.org>,
the arch/x86 maintainers <x86@...nel.org>
Subject: Re: [PATCH] x86: Don't build vDSO with $(RETPOLINE_CFLAGS)
-DRETPOLINE
On Mon, 2018-03-19 at 14:11 -0700, H.J. Lu wrote:
> vDSO code runs in userspace. Don't compile it with retpoline.
>
> Signed-off-by: H.J. Lu <hjl.tools@...il.com>
There are cases where we might actually want userspace to be using
retpoline though. We still only do IBPB for *some* processes, and
haven't really even finished the argument about the heuristics we use
for that.
If this is only for the switch in __vdso_clock_gettime() then maybe we
turn that into a series of if/else instead of a switch. Or just write
it in asm.
Or better still, teach GCC that when it's using retpoline, a jump table
is *NOT* faster than a series of that many conditional branches. The
costs are higher, and I don't think we taught GCC that yet, did we?
Download attachment "smime.p7s" of type "application/x-pkcs7-signature" (5213 bytes)
Powered by blists - more mailing lists