  Optimizing application performance? 
 The Question is:
 
Hi Wizard,
 
I'm looking for direction and resources in order to figure out how to increase
 the speed of a Fortran complied program we're running under OpenVMS.  It's
 highly computational and repetitive in nature and doesn't create multiple
 threads.  Presently, we're
running it under OpenVMS V7.1-2 on a new XP1000 workstation with the EV6.7
 processor. The program was originally compiled under Compaq Fortran V6.x.
 
We're looking at a SMP solution (DS20E with (2)EV6.7's) but have doubts that,
 because of the single-threaded nature of our program, we won't see much speed
 improvement over what we're achieving at present. Is DECthreads something we
 should look at, in ord
er to break down the single thread?  Should we recompile with V7.3 Fortran?
 
Any advice or direction you could point us in would be greatly appreciated.  We
 love VMS and want to stay with it for quite a few years to come.
 
Thanks in advance
David Warren
 
 The Answer is:
 
  Seriously consider using a tool such as the Performance and Coverage
  Analyzer (PCA; part of the Compaq DECset package), to determine exactly
  what routine(s) are the most active ("hottest").  Then determine why
  and how these "hot" routines are being used, and what you can do to
  optimize the execution of these routines.  This could be through
  optimization of the routines, through techniques designed to allow
  the compiler to better optimize the code, and through finding and
  exploiting any available opportunities for increased processing
  parallelism.
 
  As for SMP systems, you need to find opportunities for parallelism
  within the code in order to exploit a multiprocessor configuration,
  via coding the application to use parallelism tools (DECthreads, PVM,
  Linda, etc), via the use of multiple processes, or via various other
  similar techniques.  (For some of the basic background on the
  computational theories behind this, please see Amdahl's Law and
  Minsky's Conjecture...)  For a single-threaded CPU-bound application,
  the improvements resulting from an an SMP upgrade will be limited by
  the about of processing that can be off-loaded to other processors and
  thus permitting more processing for the single-threaded application.
 
  Depending on what the code is doing, you may want to use compiler
  command qualifiers such as /ARCHITECTURE=EV56 or /ARCHITECTURE=EV6
  to ask the compiler to generate instructions available on these (and
  later) generations of Alpha microprocessors.  Depending on exactly
  what the code is doing, this can provide you with faster execution.
  The /OPTIMIZE=TUNE mechanism should generally be left to the default.
 
  Use the current/latest compilers, particularly if you plan to use the
  /ARCHITECTURE qualifier.
 
  Programming-related topics include 1661 and 2681, among others.
 
