lkml.org 
[lkml]   [2011]   [Jun]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] sparc, exec: remove redundant addr_limit assignment
On Sat, Jun 11, 2011 at 04:08:42PM -0700, David Miller wrote:
> From: Mathias Krause <minipli@googlemail.com>
> Date: Fri, 10 Jun 2011 15:10:53 +0200
>
> > The address limit is already set in flush_old_exec() so this
> > assignment of USER_DS is redundant.
> >
> > Signed-off-by: Mathias Krause <minipli@googlemail.com>
> ...
> > @@ -368,9 +368,6 @@ void flush_thread(void)
> >
> > /* Clear FPU register state. */
> > t->fpsaved[0] = 0;
> > -
> > - if (get_thread_current_ds() != ASI_AIUS)
> > - set_fs(USER_DS);
> > }
>
> Yeah but now you're doing it unconditionally, the guard is here
> because the %asi register write which set_fs() does is extremely
> expensive on sparc64 and %99.99999 of the time we can avoid it.

OTOH, get_thread_current_ds() is cheap and moving that into set_fs()
itself wouldn't be particulary bad idea...


\
 
 \ /
  Last update: 2011-06-12 01:47    [W:0.077 / U:0.348 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site