[Info-vax] fortran version && Compile the main file in debug mode only
Stephen Hoffman
seaohveh at hoffmanlabs.invalid
Fri Aug 14 15:46:29 EDT 2020
On 2020-08-14 15:01:34 +0000, HCorte said:
> The why not compile everthing with debug is that some of the
> dependecies may be in use by other programs and don't know whant would
> be implications if there would be any... but know that you asked you
> are right the other programs were compile and linked without the /DEBUG
> flag at the time so it wouldn't interfere now.
I'd think that'd be a form of premature optimization. Try the build and
see, and check for the performance difference for your particular app,
if you prefer praxis.
Build it all with /DEBUG /NOOPTIMIZE. Debugging and disabling the
optimizer does make the code somewhat slower, though typically not
significantly slower, and /DEBUG /NOOPTIMIZE doesn't usually effect the
app otherwise.
"Usually"? If the app behavior does change with the debugger, the app
is usually broken. There's usually a stack corruption or timing bug or
some other latent app bug.
What you're headed for with your current approach here is more "fun"
when you find the need to step into or otherwise poke around in object
code not built /DEBUG /NOOPTIMIZE.
And you're going to be operating with your own side-built objects or
side-built object library anyway, so the whole discussion there is
seemingly moot. You're not effecting anyone else, here.
The newest OpenVMS Fortran compiler is Fortran 95. The Flang compiler
might appear on OpenVMS x86-64, but that's unlikely to arrive on older
platforms, and not arriving on your schedule. For comparison, the
newest C on OpenVMS is ~C99.
BTW: you'll want to learn about listings with machine code, and a full
linker map, as that's the means to debug an app crash back to the
associated source code, when working with /NODEBUG /OPTIMIZE.
BTW: an app can launch the debugger on itself, and can pass commands
and can script the debugging. Which can be a means to add logging and
related debugging into an app.
BTW: Documentation resources: OpenVMS Fortran User's Guide, OpenVMS
Programming Concepts Manual, OpenVMS User's Manual, Fortran Language
Reference Manual. All are posted around the 'net.
--
Pure Personal Opinion | HoffmanLabs LLC
More information about the Info-vax
mailing list