comp.lang.ada
 help / color / mirror / Atom feed
* Using ATC to abort code written in Fortran
@ 2000-01-20  0:00 Duncan Sands
  2000-01-20  0:00 ` Tucker Taft
  0 siblings, 1 reply; 2+ messages in thread
From: Duncan Sands @ 2000-01-20  0:00 UTC (permalink / raw)


I have a heavy calculation to do which may have to be aborted in the
middle,
using ATC.  Thus

select
   A.Trigger;
then abort
   Huge_Calculation;
end select;

Most of the Huge_Calculation is performed by a numerical library written

in Fortran.  I am worried that ATC may not work correctly if the abort
comes
while in the Fortran code.  Does anyone have any idea?

I can see two kinds of potential problems.  The first comes from how the
fortran
code is written.  For example, if it stores information in global
variables then these
may be left corrupted after ATC.  I'm not so worried by this, because I
can check
the code and do some rewriting if necessary.  I am more worried about
the second
kind of potential problem: will ATC trash memory etc because the code
produced
by the fortran compiler is not compatible with ATC?  I've no idea how
ATC is
implemented, so I've no idea if there could really be code compatibility
problems
or not.  Perhaps someone out there has some experience with this kind of
thing...

I am using g77 (egcs version) for compiling the fortran and GNAT 3.12p
for the
Ada.

Thanks for your help,

Duncan Sands.

PS: Of course, I could wrap the Fortran code up in a protected object,
and exploit the abort deferred property of protected objects to avoid
having the abort come during execution of the Fortran code.  But since
it is the Fortran part that is likely to need to be aborted (because it
can take a long time to complete), this is not very satisfactory.





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2000-01-20  0:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-01-20  0:00 Using ATC to abort code written in Fortran Duncan Sands
2000-01-20  0:00 ` Tucker Taft

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox