Messages in this thread | | | Date | Fri, 5 Aug 2011 22:47:40 +0200 | From | Andi Kleen <> | Subject | Re: New vsyscall emulation breaks JITs |
| |
On Fri, Aug 05, 2011 at 01:36:48PM -0700, H. Peter Anvin wrote: > On 08/05/2011 01:26 PM, Andi Kleen wrote: > >> I have to say I believe that trying to JIT the vdso or vsyscall pages is > >> extremely dubious at best. They are fundamentally different from normal > >> user space in that the kernel can muck with them any time, without > >> notifying userspace about it. The other aspect of this is that this is > >> about the legacy vsyscall page, which we're trying to get rid of, partly > >> because of security problems. > > > > There's clear evidence now you can't: it's used even by new binaries. > > time() is not supported by vdso; this is a problem. Getting rid of it > is a long-term thing.
Yes you're right the problem is time. I set a breakpoint on the vsyscalls and I get:
(gdb) bt #0 0xffffffffff600400 in ?? () #1 0x00007fffe4f703fd in time () at ../sysdeps/unix/sysv/linux/x86_64/time.S:36 ...
This is with a very new glibc, in fact a recent git version.
So clearly it's all broken and even outside JITs everyone using time() will be slow and if they use JITs don't work at all.
-Andi
-- ak@linux.intel.com -- Speaking for myself only.
| |