Boost logo

Boost :

From: Gennadiy Rozental (gennadiy_at_[hidden])
Date: 2002-09-08 12:14:54

> > In general I think that your may struggle here because of the problems
> > Rounding policy design (see my review): it's to big and unite in one
> > several implementation dependent but independent from user prospective
> > policies. This one would be The ConvertionPolicy. And though it may need
> > some staff from other rounding policies it still independent decision.
> > it become independent player it will more easy to work with it,
> > to change it.
> Why do you think they are indepedent? Is there a good reason a user would
> like to use precise computations and unprecise conversions (or the other
> way around)?

Under "They" I meant rounding abstrction "levels". Do you?

> And you say they are "implementation dependent". I would have said they
> are implementation inter-dependent.

No. Every rounding abstrction "level" only depends on lower level for it's

> You seem to think that it is easy to
> separate them. I just suggest you to give it a bit of thought, and look
> how the hardware solutions (processors FPUs) and software solutions
> (libraries like MPFR) deal with rounding. If we had done this library in
> order to be used with a specific processor or a specific library, it would
> have been possible to simplify the design yes. But we wanted to do a
> generic library, and there was only one solution: to separate all the base
> type computations dependent stuff in one policy.
> So please stop thinking we love to use over-complex thingies. We really
> give a lot of thoughts in this library.

Vice-verca, I think that the library should be a little bit more complex to
be much more flexible.

> > As I mention in my review I do not see the reason why Rounding policies
depend on T as a template parameter. Once you exclude T problem disappear by
itself. If policies defines conversions, intervals are convertible either.
> I'm not sure to know what you are talking about. If you are saying that
> the rounding is independant from the base type, you're totally wrong. > I
could give you a lot of explanations; but here is one you could easily
> verify: just look at the 'precision field' of the 'control register' of
> the x86 FPU. So, because the rounding can be type-dependent in some
> situations, it's only natural that there is a template parameter.

Could you please be more specific and point to exact location in you code.
Since I could not find nor 'precision field' nor 'control register' notions

> Regards,
> Guillaume


Boost list run by bdawes at, gregod at, cpdaniel at, john at