Boost logo

Boost :

From: Cromwell Enage (sponage_at_[hidden])
Date: 2005-05-11 08:03:44


--- Andy Little wrote:
> > There may be an implementation of gcd<> that is
> > more efficient even if it works solely on
> > big_integral<> numbers.
>
> Surely it would make sense to specialise this for
> big_integral.

Yes.

> > Or there may not, but for now, I shouldn't rule
out
> > anything that promises to make big_integral<>
> > operations less expensive.
>
> But these operations will now be unneccessarily
> expensive for small_int types.

Then there should be a gcd specialization for them,
too, right? One that doesn't require recursive
apply2<> calls?

> Your version of gcd looks is obviously optimised
> for big_integral.

Really? I haven't even taken advantage of anything
that's specific to big_integral<>, but okay...

...if I ever get big_integral<> to work.

> However my requirements on rational would be for a
> large number of smallint types. I hope you will
take
> this into account in the design and favour the
> implementation more towards small_int types as well.

Okay.

> OK maybe that would be quicker, and give better
error
> messages. But you will need a tag dispatch
mechanism
> anyway wont you?, to avoid a large number of
> specialisations.

Yes. Like I said, I'll do that.

                              Cromwell D. Enage

                
Discover Yahoo!
Find restaurants, movies, travel and more fun for the weekend. Check it out!
http://discover.yahoo.com/weekend.html


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk