Boost logo

Boost :

Subject: Re: [boost] Updating the Boost Review Process Was: [GGL] Bost.Polygon (GTL) vs GGL - rationale
From: Barend Gehrels (barend_at_[hidden])
Date: 2009-11-19 12:09:43


> Perhaps it is at least as far as you've tested it since fixing some of
> the issues found in the review. The casting bits both explicit and
> implicitly in things like less<double>/greater<double> are still there
> and would mean your GMP types are cast to double for these predicates.
But where did I write that *everything* works with GMP? I thought I
mentioned, everywhere where I talked about this, that it is working
*some* algorithms (area etc). See what I just answered:

>
>> - It was not implemented in *all *algoritms, as I mailed on this list
>> before, including the reason for that

>
> As I said above (and please everyone, don't take my word for it.. do a
> search for 'double' on the project), the locations of these instances
> would seem to pollute much of the core algorithms which are likely
> interdependent.
A search will find many, even in area. The default calculation for area
uses at least a double, as stated in the source code:
// Else, use the pointtype, but at least double
this means, if you use float, area calculation uses double, unless
specified else.
But it also means, if you use GMP, area calculation uses GMP.

>
>> - that 1e-10 tolerance occurs only once in the whole code, at a place
>> setting a boolean flag is often set anyway. That is noted there
>> - furthermore we compare : integer with ==, FP with epsilon (like in
>> Boost.Test) and GMP or CLN with == . See ggl/util/math.hpp
>
> Yes, I agree there was only one instance of this, but it is relevant
> nonetheless.
I don't think it is relevant. I explicitly commented that in the source
code there:
"So it is never harmful to do this with a larger epsilon."
I know that 1e-10 is too large, for FP comparisons.

>
>> - there is nothing concocted on the fly of this review, besides maybe
>> things really not implemented (as our answer to Pierre about
>> infinity), but they are not presented as being there or already planned
>>
>
> I would consider changing the things I have mentioned as being
> concocted on the fly. How can you claim that GGL works with GMP when
> you have code that casts it to a double internally? I consider this
> point to be incontrovertible.
See above. I still claim this. Area really uses GMP and GMP only, if
specified. If you specify, it uses CLN and CLN only. I've explicitly
tested it to avoid castings.

What I didn't claim is that it working everywhere, and I think that I've
mentioned that in all my postings. Didn't check them now, but if not,
sorry about that.

Finally, I didn't react on this:
> I really want to contribute to the geometry efforts as I believe I
> have something to offer
but I was happy to read that part of course.

Regards, Barend


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