On 04/15/2014 07:44 AM, Hazen Babcock wrote:
> On 4/7/2014 11:08 PM, Alan W. Irwin wrote:
>> I have just had a further idea. For comprehensive testing situations
>> it might be good to have the option to call feenableexcept (the C
>> library function that you used to help debug x29c.c that should be
>> available for c99 according to its Linux man page) from within the
>> PLplot library (say as the result of plinit).  If you agree (a) that
>> idea would work and (b) it would be useful, would you be willing to
>> implement it in C for the case when the PLPLOT_ENABLE_FLOAT_EXCEPT C
>> macro is #defined?  If so, I would be willing to do the rest on the
>> CMake side (create a CMake option for this and propagate it to the
>> corresponding C macro for the compilation of the source file where you
>> have implemented the feenableexcept call).
>
> I have tested the idea and it works. I'm not sure about the utility
> though. Based on my tests it already caught the only error in the
> examples that it is going to catch. After the git transition I can
> create a branch that will catch floating point exceptions and you can
> merge it (or not) into the master branch based on your feeling about
> it's utility.

Much time passes during which I never implement this branch as promised, 
and it looks like some more floating point exceptions have crept in. 
More specifically I'm seeing floating point exceptions in x25, x30 and 
x33. The problem seems to be with plgradient() when it uses a software 
fallback gradient (I was testing with the xwin driver).

You can pull a branch with floating point exception trapping enabled for 
these examples here:
https://github.com/HazenBabcock/PLplot/tree/fpe_x25_x30_x33

The problem is occurring in notcrossed() in plfill.c at line 2040 when 
converting from a PLFLT to a PLINT. It looks like fxintersect and 
fyintersect can take on values that are too large to be converted to 
integers. Checking for this fixes the problem, but maybe this is 
indicating some problem upstream?

-Hazen


------------------------------------------------------------------------------
One dashboard for servers and applications across Physical-Virtual-Cloud 
Widest out-of-the-box monitoring support with 50+ applications
Performance metrics, stats and reports that give you Actionable Insights
Deep dive visibility with transaction tracing using APM Insight.
http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to