Re: [PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-19 Thread Thomas Gleixner
Dmitry, On Mon, 19 Aug 2019, Dmitry Safonov wrote: > On 8/18/19 5:21 PM, Thomas Gleixner wrote: > > That means your timens_to_host() and host_to_timens() conversion functions > > should just use that special VDSO page and do the same array based > > unconditional add/sub of the clock specific

Re: [PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-19 Thread Dmitry Safonov
Hi Thomas, On 8/18/19 5:21 PM, Thomas Gleixner wrote: [..] > I'm happy to review well written stuff which makes progress and takes > review comments into account or the submitter discusses them for > resolution. Thanks again for both your and Andy time! [..] > Coming back to Andy's idea. Create

Re: [PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-18 Thread Thomas Gleixner
On Sun, 18 Aug 2019, Thomas Gleixner wrote: > On Sun, 18 Aug 2019, Thomas Gleixner wrote: > > > > Patch below. I tested this with the normal order and by installing a > > 'timens' page unconditionally for all processes. I'll reply with the timens > > testing hacks so you can see what I did. > >

Re: [PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-18 Thread Thomas Gleixner
On Sun, 18 Aug 2019, Thomas Gleixner wrote: > > Patch below. I tested this with the normal order and by installing a > 'timens' page unconditionally for all processes. I'll reply with the timens > testing hacks so you can see what I did. First hack... Thanks, tglx 8<-

Re: [PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-18 Thread Thomas Gleixner
Dmitry, On Fri, 16 Aug 2019, Dmitry Safonov wrote: > On 8/16/19 9:10 PM, Thomas Gleixner wrote: > > On Fri, 16 Aug 2019, Andy Lutomirski wrote: > [..] > >> I'm unconvinced that any of this magic is wise. I think you should make a > >> special timens vvar page that causes the normal fastpath to

Re: [PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-16 Thread Dmitry Safonov
Hi Andy, Thomas, thank you very much for your time and the reviews, appreciate that. On 8/16/19 9:10 PM, Thomas Gleixner wrote: > On Fri, 16 Aug 2019, Andy Lutomirski wrote: [..] >> I'm unconvinced that any of this magic is wise. I think you should make a >> special timens vvar page that causes

Re: [PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-16 Thread Thomas Gleixner
On Fri, 16 Aug 2019, Andy Lutomirski wrote: > On 8/15/19 9:38 AM, Dmitry Safonov wrote: > > As it has been discussed on timens RFC, adding a new conditional branch > > `if (inside_time_ns)` on VDSO for all processes is undesirable. > > It will add a penalty for everybody as branch predictor may

Re: [PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-16 Thread Andy Lutomirski
On 8/15/19 9:38 AM, Dmitry Safonov wrote: As it has been discussed on timens RFC, adding a new conditional branch `if (inside_time_ns)` on VDSO for all processes is undesirable. It will add a penalty for everybody as branch predictor may mispredict the jump. Also there are instruction cache

[PATCHv6 23/36] x86/vdso: Allocate timens vdso

2019-08-15 Thread Dmitry Safonov
As it has been discussed on timens RFC, adding a new conditional branch `if (inside_time_ns)` on VDSO for all processes is undesirable. It will add a penalty for everybody as branch predictor may mispredict the jump. Also there are instruction cache lines wasted on cmp/jmp. Those effects of