Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

7.0;hpc (histogram_pc), revision 7.0, 83/09/06
HPC (HISTOGRAM_PROGRAM_COUNTER) -- Make a histogram of the program counter.
usage:  HPC [-LOW x] [-HIGH x] [-RATE n] pathname [args...]


FORMAT

  HPC [options] pathname [args...]


  HPC produces a histogram of the program counter during program execution, thus
  helping you locate the most time-consuming portions of your program.

  While  your  program  is executing, HPC samples the program counter at regular
  intervals, gathering a set of data points.  Each data point is the address  at
  which  the  program was executing -- that is, the value of the program counter
  -- when the sample was taken.

  When execution of your program  has  ended,  HPC  displays  statistics  and  a
  histogram (bar graph) of the program counter.  Each bar corresponds to an area
  of  program memory.  The length of the bar indicates how much time the program
  spent executing in the corresponding area.

  While HPC and your program are executing, serial line  3  (SIO3)  (line  2  on
  DN300 systems) is not available for output.


ARGUMENTS

  pathname
  (required)         Specify the name of the program to be evaluated.

  args
  (optional)           Specify  any  arguments  to  be  passed  to  the  program
                     "pathname".  These are not processed  by  HPC,  but  passed
                     directly to your program.

                     Default if omitted:  no arguments passed


OPTIONS

  If  no  options are specified, a histogram is produced for the entire program,
  with 500 samples taken per second.

  -LOW x              Specify  lowest  address  ("x")  to  be  included  in  the
                     histogram. "x" must be a hexadecimal value.  If this option
                     is  omitted,  the  histogram starts at the beginning of the
                     program.

  -HIGH x            Specify  highest  address  ("x")  to  be  included  in  the
                     histogram.    "x"  must  be  a  hexadecimal value.  If this
                     option is omitted, the histogram continues to  the  end  of
                     the program.

                     By  limiting  the  range of addresses in the histogram with
                     -LOW and -HIGH, you can  study  a  specific  part  of  your
                     program, such as an I/O routine.

  -RATE n             Specify  how  many  times  ("n")  HPC  samples the program
                     counter per second.  "n" must be a decimal  number  in  the
                     range 5 to 2000.  The default is 500 samples per second.  A
                     higher rate results in a more accurate histogram, but tends
                     to slow program execution.


EXAMPLES

  For  a detailed example of HPC, see the HPC command description in the "DOMAIN
  System Command Reference Manual."

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026