avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] [avr-libc-commit] [2358] Reverted month_length() back


From: Joerg Wunsch
Subject: Re: [avr-libc-dev] [avr-libc-commit] [2358] Reverted month_length() back to using the 'knuckles' algorithm.
Date: Wed, 24 Apr 2013 20:30:50 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

As Weddington, Eric wrote:

> > -    return 30 + ((month + month / 8) & 1);

> You're dividing by 8. Did you try replacing the divide with a right
> shift? Would that get you better code size?

That's the old, dismissed version anyway.

I agree with Mike that the "knuckles" algorithm is easier to
understand.
-- 
cheers, Joerg               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/
Never trust an operating system you don't have sources for. ;-)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]