Mini-Unix/usr/doc/hel/hel3

.h0 "\na.\n+b Basic Program Development Package"
.nr c 0 1
.sp
.in0
A kit of fundamental programming tools.
Some of these utilities are used as integral parts of
the higher level languages described below.
.sh AR
Archive and library maintainer.
Combines several files into one for housekeeping efficiency.
Archive files are used by the link editor LD as libraries.
.op
Create new archive.
.op
Update archive by date.
.op
Replace or delete files.
.op
Table of contents.
.op
Retrieve from archive.
.sh AS
Assembler.
Similar to PAL-11, but different in detail.
.op
Creates object program consisting of
.in+2
.nf
code, possibly read-only,
initialized data or read-write code,
uninitialized data.
.in -2
.fi
.op
Relocatable object code is directly executable without
further transformation.
.op
Object code normally includes a symbol table.
.op
Combines source files.
.op
Local labels.
.op
Conditional assembly.
.op
\*(lqConditional jump\*(rq instructions become
branches or branches plus jumps depending on distance.
.sh Manual
Printed manual for the assembly language.
.sh Library
The basic run-time library.
These routines are used freely by all system software.
.op
Formatted writing on standard output.
.op
Time conversions.
.op
Convert integer and floating numbers to ASCII and vice versa.
.op
Elementary functions: sin, cos, log, exp, atan, sqrt, gamma.
.op
Password encryption.
.op
Quicksort.
.op
Buffered character-by-character I/O.
.op
Random number generator.
.op
Floating point interpreter for 11/40's and non-floating point
machines.
.sh (LIBP)
An elaborated I/O library.
.op
Formatted input and output.
.op
Ability to put characters back into input streams.
.sh Manual
Printed manual for LIBP.
.sh DB
Interactive post-mortem debugger.
Works on core dump files, such as are produced by all
program aborts, on object files, or on any arbitrary file.
.op
Symbolic addressing of files that have symbol tables.
.op
Octal, decimal or ASCII output.
.op
Symbolic disassembly.
.op
Octal or decimal patching.
.sh OD
Dump any file.
.op
Output options include:
.in+2
octal or decimal by words,
.br
octal by bytes,
.br
ASCII,
.br
opcodes,
.br
hexadecimal,
.br
any combination of the above.
.op
Range of dumping is controllable.
.sh LD
Link edit.
Combine relocatable object files.
Insert required routines from specified libraries.
.op
Resulting code may be sharable.
.op
Resulting code may have separate instruction and data spaces.
.sh NM
Print the namelist (symbol table) of an object program.
Provides control over the style and order of
names that are printed.
.sh SIZE
Report the core requirements
of one or more object files.
.sh STRIP
Remove the relocation and symbol table information from
an object file to save space.
.sh TIME
Run a command and report timing information on it.
.sh PROF
Construct a profile of time spent per routine
from statistics gathered by time-sampling the
execution of a program.
Uses floating point.
.op
Subroutine call frequency and average times for C programs.
.h0 "\na.\n+b The Programming Language ``C''"
.nr c 0 1
.nr b 0 1
.sh CC
Compile and/or link edits programs in the C
language.
The U\s8NIX\s10 operating system, most of the
subsystems and C itself are written in C.
.op
Full general purpose language
designed for structured programming.
.op
Data types:
.nf
.in+2
character,
integer,
float,
double,
pointers to all types,
arrays of all types,
structures of all types,
functions returning all types.
.in-2
.fi
.op
Operations intended to give
access to full machine facility, including to-memory
operations and data-sensitive
pointer arithmetic.
.op
Macro preprocessor for parameterized code and inclusion of
standard files.
.op
All procedures recursive, with parameters by value.
.op
Natural coercions.
.op
True compiled object code capitalizing on
addressing capability of the PDP11.
.op
Runtime library gives access to all system facilities.
.sh Manuals
Printed manual and tutorial for the C language.
.sh CDB
An interactive debugger tailored for use with C.
.op
Usable in real time or post-mortem.
.op
The debugger is a completely separate process from the debuggee.
No debugging code is loaded with debuggee.
.op
Prints all kinds of data in natural notation:
.nf
.in+2
character,
integer (octal and decimal),
float,
double,
machine instructions (disassembled).
.in -2
.fi
.op
Stack trace and fault identification.
.op
Breakpoint tracing.
.h0 "\n+a Other Languages"
.nr b 0 1
.h0 "\na.\n+b FORTRAN"
.sh FC
Compile and/or link-edit FORTRAN IV programs.
Object code is \*(lqthreaded\*(rq.
Relies heavily on floating point.
.op
Idiosyncracies:
.nf
.in+2
free form, lower-case source code,
no arithmetic statement functions,
unformatted I/O requires record lengths agree,
no BACKSPACE,
no P FORMAT control on input.
.in-2
.fi
.op
Handles mixed-mode arithmetic,
general subscripts and general DO limits.
.op
32-bit integer arithmetic.
.op
Free format numeric input.
.op
Understands these nonstandard specifications:
.in+2
LOGICAL*1, *2, *4,
.br
INTEGER*2, *4,
.br
REAL*4, *8,
.br
COMPLEX*8, *16,
.br
IMPLICIT.
.in-2
.fi
.sh RC
``Ratfor'', a preprocessor that adds rational
control structure \o'a\(ga' la C to FORTRAN.
.op
Else, for, while,
repeat...until
statements.
.op
Symbolic constants.
.op
File insertion.
.op
Compound statements.
.op
Can produce genuine FORTRAN to carry away.
.sh Manual
Printed manual for Ratfor.
.h0 "\na.\n+b Other Algorithmic Languages"
.nr c 0 1
.sh BAS
An interpreter, similar in style to BASIC, that allows
immediate execution of unnumbered statements, or deferred
execution of numbered statements.
.op
Statements include:
.in+2
.nf
comment,
dump,
for...next,
goto,
if...else...fi,
list,
print,
prompt,
return,
run,
save.
.fi
.op
All calculations double precision.
.op
Recursive function defining and calling.
.op
Builtin functions include log, exp, sin, cos, atn, int,
sqr, abs, rnd.
.op
Escape to ED for complex program editing.
.op
Usable as a filter.
.sh DC
Programmable reverse Polish desk calculator.
Has named storage locations as well
as conventional stack for holding integers or programs.
.op
Unlimited precision decimal arithmetic.
.op
Appropriate treatment of decimal fractions.
.op
Arbitrary input and output radices, in particular
binary, octal, decimal and hexadecimal.
.op
Operators include:
.in+2
.nf
+ \- * /
remainder, power, square root,
load, store, duplicate, clear,
print, enter program text, execute.
.in-2
.fi
.op
Usable as a filter.
.sh BC
A C-like interface to the desk calculator DC.
.op
All the capabilities of DC with a high-level syntax.
.op
Arrays and recursive functions.
.op
Immediate evaluation of expressions and evaluation of
functions upon call.
.op
Arbitrary precision elementary functions:
exp, sin, cos, atan, J\v'.3'\s8n\s10\v'-.3'.
.op
Go-to-less programming.
.op
Usable as a filter.
.sh Manual
Printed manual for BC.
.sh SNO
An interpreter very similar to SNOBOL 3.
.op
Limitations:
.nf
.in+2
function definitions are static,
pattern matches are always anchored,
no built-in functions.
.in-2
.fi
.op
Usable as a filter.
.sh Manual
Reprint of basic article.
.h0 "\na.\n+b Macroprocessing"
.nr c 0 1
.sh M6
A general purpose macroprocessor.
.op
Stream-oriented, recognizes macros anywhere in text.
.op
Integer arithmetic.
.op
Usable as a filter.
.sh Manual
Printed manual for M6.
.h0 "\na.\n+b Compiler-compilers"
.nr c 0 1
.sh TMG
A classical top-down compiler-compiler language.
Provides a formalism for syntax-directed translation.
Produces driving tables to be loaded with a standard
interpreter.
.op
Resulting compilers can have arbitrary tables kept in
paged secondary store.
.op
Integer arithmetic capability.
.op
Syntactic function capability (similar to ALGOL 68
metaproductions).
.sh Manual
Printed manual for the TMG compiler-writing system.
.sh YACC
An LR(1)-based compiler writing system.
During execution of resulting
parsers, arbitrary C-language, Ratfor or FORTRAN functions may be
called to do code generation or semantic actions.
.op
BNF syntax specifications.
.op
Handles precedence relations.
.op
Accepts formally ambiguous grammars
with non-BNF resolution rules.
.op
Optimizes space 
taken by driving tables.
.sh Manual
Printed manual for the YACC compiler-writing system.
.h0 "\n+a Word Processing"
.nr b 0 1
.sh ROFF
A typesetting program for terminals.
Easy for nontechnical people to learn, and good
for most ordinary kinds of documents.
Input consists of data lines intermixed with control lines,
such as
.ta  8n
.ti 10
.li
.sp 2	insert two lines of space
.ti10
.li
.ce	center the next line
.br
.op
Justification of either or both margins.
.op
Automatic hyphenation.
.op
Generalized running heads and feet, with even-odd page
capability, numbering, etc.
.op
Definable macros for frequently used
control sequences (no substitutable arguments).
.op
All 4 margins and page size dynamically adjustable.
.op
Hanging indents and one-line indents.
.op
Absolute and relative parameter settings.
.op
Optional legal-style numbering of output lines.
.op
Multiple file capability.
.sh CREF
Make cross-reference listings of a collection of files.
Each symbol is listed together with file, line number, and
text of each line in which it occurs.
.op
Assembler or C language.
.op
Gathering or suppressing references to selected symbols.
.op
Last symbol defined may replace line number.
.op
Various ways to
sort output available.
.op
Selective print of uniquely occurring symbols.
.sh INDEX
Make cross-reference indexes of English text.
.op
Handles lists of specific index terms or excluded terms.
.op
Handles words hyphenated across lines.
.op
Understands TROFF and NROFF output, so can gather
references according to final pagination.
.op
Output capabilities like CREF.
.op
Frequency counts.
.sh FORM
Form letter generator.
Remembers any number of forms and stock phrases such as names
and addresses.
Output usually intended to be ROFFed.
.op
Anything that is typed in can be remembered for later use.
.op
Runs interactively, querying only for those items
that are not in its memory.
.op
Any item may call for the inclusion
of other items.
For example, full name, address, first name, title, etc.,
may be separately retrieved from one name key.
.sh FED
Editor for 
the memory used by FORM.
Extract any item, turn it over to context editor ED for
editing, and put it back when done.
.op
List names of selected items.
.op
Print contents of selected item.
.sh SORT
Sort or merge ASCII files line-by-line.
.op
Sort up or down.
.op
Sort lexicographically or on numeric key.
.op
Multiple keys located by delimiters or by character position.
.op
May sort upper case together with lower into dictionary order.
.op
Usable as a filter.
.sh UNIQ
Collapse successive duplicate lines
in a file into one line.
.op
Publishes lines that were originally unique,
duplicated, or both.
.op
May give redundancy count for each line.
.op
Usable as a filter.
.sh TR
Do one-to-one character translation according to
an arbitrary code.
.op
May coalesce selected repeated characters.
.op
May delete selected characters.
.op
Usable as a filter.
.sh DIFF
Report line changes, additions and deletions necessary to bring two files
into agreement.
.op
May produce an editor script to convert one file into another.
.sh COMM
Identify common lines in two sorted files.
Output in up to 3 columns shows lines present in first file only,
present in both, and/or present in second only.
.sh CMP
Compare two files and report disagreeing bytes.
.sh GREP
Print all lines in a file that satisfy
a pattern of the kind used in the editor ED.
.op
May print all lines that fail to match.
.op
May print count of hits.
.op
Usable as a filter.
.sh WC
Count the lines and \*(lqwords\*(rq (blank-separated strings) in a file.
.op
Usable as a filter.
.sh TYPO
Find typographical errors.
Statistically analyzes all the words in a text, weeds out
several thousand familiar ones, and publishes the rest sorted so that
the most improbably spelled ones
tend to come to the top of the list.
.sh GSI
Simulate Model 37 Teletype facilities on
GSI-300, DASI and other Diablo-mechanism terminals.
.op
Gives half-line and reverse platen motions.
.op
Approximates Greek letters and other special characters
by overstriking.
.op
Usable as a filter.
.sh COL
Canonicalize files with reverse line feeds
for one-pass printing.
.op
Usable as a filter.