lkml.org 
[lkml]   [1998]   [Sep]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Non-urgent issue with fs/isofs/util.c
From
Date
"Helge Hafting" <helge.hafting@daldata.no> writes:

|> In <19980918151457.C9740@harvestroad.com.au>, on 09/18/98
|> at 03:14 PM, Ian McKellar <imckellar@harvestroad.com.au> said:
|> >I don't think we need to be to concerned right now, but changing:
|> > if (((year+2) % 4) == 0 && month > 2)
|> >to:
|> > if (((year+2) % 4) == 0 && month > 2 && year != 130) should
|> >fix it.
|> The equivalent code
|> if (!((year+2) & 3) && month > 2 && year != 130) is probably
|> faster. The somewhat expensive mod operator is
|> replaced by a bitwise "and", that is faster on most platforms.

GCC does that conversion by itself.

--
Andreas Schwab "And now for something
schwab@issan.informatik.uni-dortmund.de completely different"
schwab@gnu.org

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:44    [W:0.040 / U:0.532 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site