hmmm, isn't that a bit much? I mean, you can't really expect to memoize
date math.

--d

Dr.Ruud wrote:
> Daisuke Maki schreef:
> 
> 
>>  - Date math is terribly slow. Most of performance improvements
>>    from DT::TZ came from reducing the number of calls to
>>    DateTime::add_duration(). For example,
>>
>>       my $diff = $dow - $dt->day_of_week;
>>       $dt->add(days => $diff);
>>
>>    is definitely faster than
>>
>>       while ($dt->day_of_week != $dow) {
>>         $dt->add(days => 1);
>>       }
>>
>>   That also means that if we can somehow speed up DT::add_duration(),
>>   then overall perfomance will improve significantly
> 
> 
> Dit you also test with Memoize?
> 

Reply via email to