On 2016-02-26 22:45-0500 Hazen Babcock wrote:

> On 02/26/2016 05:18 PM, Alan W. Irwin wrote:
[...]
>> But I have to admit you [Phil] have
>> already made a fairly convincing argument for error reporting via C
>> exception handling, and if you look at the caller graphs I prepared
>> there are some instances (even if we have immediate exit for memory
>> emergencies) where the return value approach would be quite
>> complicated.
>
> Such as?

Hi Hazen:

To give you an immediate fairly complex example look at the call graph
and caller graph of grline in
<http://plplot.sourceforge.net/doxygen/html/plcore_8c.html>. The
caller graph includes some 50 functions while its call graph includes
calls to plexit and one of those calls in plsave_set_locale is not
anything to do with memory allocation so there is no question we would
have to deal with it in our error report system.

So that is already a pretty complicated example, but I just discovered
that is just scratching the surface because the large call/caller
graphs generated by doxygen are partitioned (as indicated by the red
box around some references) so a given caller graph being presented on
a single plot is in complex cases a subset of the complete result. For
example, the caller graph for plsave_set_locale (in
<http://plplot.sourceforge.net/doxygen/html/plctrl_8c.html> this time)
does not include all the complications of the grline caller graph.
Instead, it summarizes that 50-function call graph as a red box around
grline with no further details. So I think to get the full picture for
either a large call graph or caller graph you have to click on all the
red boxes. Anyhow, please browse and click on these graphs including
the red boxes to draw your own conclusions about the complexity of the
call graphs that the return code approach for error reporting would
have to deal with.

I will stop there because I don't have the technical expertise to
answer the concerns you expressed about using C exception handling
(implemented with setjmp/longjmp) as the complete basis of the error
reporting system for PLplot that Phil apparently has in mind. 
However, I assume Phil will answer your concerns.

Alan
__________________________
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__________________________

Linux-powered Science
__________________________

------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
_______________________________________________
Plplot-devel mailing list
Plplot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-devel

Reply via email to