








                       Pascal-VU installation guide


                            Johan W. Stevenson

                           Wiskundig Seminarium
                            Vrije Universiteit
                                 Amsterdam





1.  Introduction

     This document describes the process of installing  Pascal-VU  at  your
UNIX  version  7 installation, running on a PDP-11 machine.  We assume that
you have standard version 7 as distributed by Bell Labs.  Pascal-VU can  be
installed on machines with or without hardware floating point unit, with or
without separate instruction and data spaces.

     Pascal programs can be run in two different ways.  The first way is to
compile  programs  to an intermediate code, called EM-1, and then interpret
the EM-1 code.  The advantages of interpretation are fast  compilation  and
extensive  run  time  checking.   It  is  especially  suited for a teaching
environment and for program debugging.

     The second way of running Pascal programs is by translating  the  EM-1
instructions  to  PDP-11  code.   The UNIX assembler and loader are used to
produce a direct executable program.   The  advantage  is  fast  execution,
about 7 times faster than with interpretation.

     We offer you two options for installation: one is the interpreted ver-
sion only, the second is the interpreted and the compiled version together.
Only the compiled version is not worth the trouble,  because  you  have  to
install  nearly  all  the files for the interpreted version as well.  These
two options are indicated by the letters 'I' and 'C'.

2.  Restoring tree

     The process of installing Pascal-VU  is  quite  simple.   The  program
'make'  is  used  to  do  the hard work.  It is important that the original
Pascal-VU distribution tree structure is restored.  Proceed as follows

  -  Create a directory, for example /usr/src/cmd/pc, on a device  with  at
     least 4000 blocks left.

  -  Change to that directory (cd ...); it will be the working directory.






                              April 15, 1980





                                   - 2 -


  -  Extract all files from the distribution medium, for instance magtape.

  -  Keep a copy of the original distribution to be able to repeat the pro-
     cess  of  installation in case of disasters.  This copy is also useful
     as a reference point for diff-listings.

The tree structure should be the same as  found  on  the  file  TREE.   The
directories contain the following information:

  ass         EM-1 assembler
  distr       documentation and manuals
  distr/backup
              improved backup routine for machines without I/D space
  distr/backup/test
              several test programs for this backup routine
  distr/doc   several documents
  distr/man   UNIX man pages
  etc         error message files and tables
  h           header files for C preprocessor
  int         EM-1 interpreter
  libem       EM-1 instruction routines for programs translated  to  PDP-11
              code
  libmon      system call interface routines
  libpc       several external routines
  libpr       Pascal run time support routines
  misc        several smaller programs
  opt         EM-1 optimizer
  pdp         translator from EM-1 to PDP-11 code
  pem         the Pascal compiler proper
  test        Pascal and EM-1 test programs
  tools       handy programs, not necessary for installation

All pathnames mentioned in the text of this document are  relative  to  the
working directory, unless they start with '/'.

     The person doing the installation needs permission  to  write  in  the
directories  of the Pascal-VU distribution tree.  Preferably you should log
in as sys (uid=3,gid=0).

3.  Fixes to your UNIX system

     Before Pascal-VU can be installed you  have  to  repair  several  bugs
found  in  the standard version 7 UNIX system.  The file "distr/v7bugs.doc"
gives for each of the following bugs a small test program and a diff  list-
ing of the source files that have to be modified.

  1  Bug in the C optimizer for unsigned comparison
  2  The loader 'ld' fails for large data and text portions
  3  Floating point registers are not saved if more memory is needed.
  4  Floating point registers are not copied to child in fork().

It is not useful to proceed with the installation of Pascal-VU, if  you  do
not  succeed  in  fixing  these  bugs.  Use the test programs to see if the
errors are present in your system and to check  if  the  modifications  are



                              April 15, 1980





                                   - 3 -


effective.

     Another very delicate problem is the kernel backup  routine  found  in
"/usr/sys/conf/m??.s".   The task of this routine is to undo all changes to
registers, whenever a program traps because of a segmentation violation, so
that  the  same instruction can be restarted later on.  Machines with 11/45
or 11/70 type memory management unit are equipped with a hardware  register
SSR1,  that gives sufficient information.  Smaller machines like the 11/34,
11/40 or 11/60 lack this register.  The backup routine for  these  machines
is long and tricky.

     The main problem, however, is that these machine  are  all  different.
For example, if the instruction

        clr     (r5)+

causes a memory-fault on an 11/40, then the register r5 is  already  incre-
mented,  while  on an 11/34 it is not.  The autodecrement modes are handled
the same on all machines, so that C programs do not give problems.   Pascal
programs,  however,  have their stack grow upwards, using the autoincrement
mode to push items on the stack.

     If you have one of the smaller machines, you should try the  following
assembly program to test your backup routine:

        start:  mov     $end,r4
                mov     $end,r5
        1:
                clr     (r5)+
                clr     (r4)+
                br      1b
        end:    0

By inspecting the core file caused by the memory-fault, you must check  the
values  of  r4 and r5.  They should be the same, probably 0100.  Proceed as
follows:

        $ as test.s; : test.s is the name of the program given above
        $ a.out
        Memory fault - core dumped
        $ echo '$' | adb
        no process
        ps      0170004
        pc      012     start+012
        sp      0177652
        r5      0100
        r4      0100
        r3      0
        r2      0
        r1      034742
        r0      05162
        start+012:      clr     (r5)+
        $




                              April 15, 1980





                                   - 4 -


If you have an 11/34 you are likely to discover that r4  and  r5  are  dif-
ferent.   By replacing lines 4 and 5 in test.s you can check other instruc-
tions easily.  Try the following instructions:

        mov     $0,(r5)+
        movf    fr0,(r5)+
        movfi   fr0,(r5)+
        stfps   (r5)+
        stst    (r5)+

An improved backup routine is available in  the  directory  "distr/backup".
Several  options  should  be set to reflect your processor characteristics.
The directory "distr/backup/test" contains several test programs,  provided
by  the  University  of  Edinburgh.   Many  of  the  problems with previous
releases of Pascal-VU were caused by an incorrect  backup  routine  on  the
target processor.

     Note that version 7 is only supported by  Bell  Labs  for  the  bigger
PDP-11 machines: 11/45 and 11/70.  We have succeeded in producing a version
7 system for the smaller machines, however, so  that  it  is  realistic  to
foresee installation of Pascal-VU on small machines as well.

4.  Options

     All sources of the Pascal-VU system are heavily  parameterized.   This
allows  installation  on a wide range of processors.  Several categories of
options can be distinguished:

UNIX version
     This distribution kit is intended for UNIX version  7,  but  the  same
     source  files  can  be used for version 6 and some intermediate forms.
     However, to simplify installation we have decided  to  make  different
     distribution  kits  for  version 6 and version 7.  These kits are dif-
     ferent in many respects: archive format, use of  'make',  file  system
     format, etc.

C compiler
     Four possibilities: version 7 C, version 6  C,  an  intermediate  form
     called  NC6, strongly resembling version 7, and a local C to EM-1 com-
     piler with slight restrictions  on  function  arguments  and  results.
     This distribution kit is configured for standard version 7 C.

Path names
     This subject is treated more  extensively  in  one  of  the  following
     chapters.   This  distribution  kit  is configured with pathnames that
     should not cause problems on standard version 7 systems.

Machine characteristics
     The distribution kit  is  configured  for  machines  without  separate
     instruction  and  data space and without hardware floating point unit.
     This makes the distribution kit suited for  all  type  of  processors,
     without  any  modification.   However, it is recommended that you make
     some minor changes if your machine has separate address spaces  and/or
     hardware floating point.  It is NOT necessary to recompile any program



                              April 15, 1980





                                   - 5 -


     after these modifications.

     The directory "h" contains several header files, used by the C prepro-
cessor  or the UNIX assembler 'as'.  The file "h/path.h" contains pathnames
and is explained below.  The files "h/local.h" and "h/local.s" contain  the
other options.  The first file is used by the C preprocessor, the second by
'as'.  Pathnames and options  are  also  found  in  "*/Makefile",  used  by
'make'.   These  files are not preprocessed, so they cannot use the options
and pathnames of "h/*".

A listing of the files "h/local.h" and "h/local.s" follows:

        h/local.h:
           1    /* collection of options, selected by including or exclud
           2
           3    /* select only one of the following: */
           4    #       define  V7              1       /* Unix version 7
           5    /* #    define  V6              1       /* Unix version 6
           6    /* #    define  VPLUS           1       /* Unix version 6
           7
           8    /* select only one of the following: */
           9    #       define  C7              1       /* version 7 C-co
          10    /* #    define  C6              1       /* version 6 C-co
          11    /* #    define  NC6             1       /* something betw
          12
          13    #ifdef BOOT
          14    #       define  INT_ONLY        1
          15    #endif
          16
          17    #ifndef BOOT
          18    /* #    define  HARDWARE_FP     1       /* if you've hard
          19    /* #    define  INT_ONLY        1       /* for interprete
          20    #       define  SFLOAT          1       /* for single pre
          21    #endif
          22
          23    /* Version number of the EM1 object code */
          24    #       define  VERSION         2       /* 16 bits number

        h/local.s:
           1    / all switches must have values 0 or 1
           2
           3    / only one of the following switches may be set:
           4    V7      = 1             / Unix version 7
           5    V6      = 0             / Unix version 6
           6    VPLUS   = 0             / Unix version 6 plus Bell diff l
           7
           8    / if the next switch is set then use single precision flo
           9    SFLOAT          = 1
          10    / set the next switch if you have hardware floating point
          11    HARDWARE_FP     = 0


     Note that the files  "h/bootpath.h"  and  "int/local.s"  also  contain
pathnames  and  options.  These files are used to recompile all sources and



                              April 15, 1980





                                   - 6 -


should NOT be changed.

     For each of the mentioned options we will give an exhaustive  list  of
files  that have to be modified if such option must be changed.  Be careful
to change all these files in the same sense, i.e. if the hardware  floating
point  option  is set in "h/local.h", then it must be set in "h/local.s" as
well, but NOT in "int/local.s".

HARDWARE_FP
     Default off. Switch on only if you do NOT need the  software  floating
     point simulator to emulate the 11/45 type floating point instructions.
     This option is switched on by changing the following files:

     h/local.h:
          Remove the first three characters of line 18.

     h/local.s:
          Replace the '0' on line 11 by '1'.

SEP_OPT
     Default off. Switch on only if your machine has two  separate  address
     spaces.  The following files should be changed to set this option:

             pem/Makefile, line 4
             opt/Makefile, line 3
             ass/Makefile, line 3
             pdp/Makefile, line 3

     The last character ('n') of these lines should be replaced by 'i',  so
     that these lines ALL look like:

             SEP_OPT=-i


INT_ONLY
     Default off. This option should only be altered if you never  want  to
     compile  Pascal  programs  into PDP-11 code.  In that case the calling
     program 'pc' can be instructed, by setting this option, to use  inter-
     preted  versions  of  the compiler proper (pem) and the two conversion
     programs (encode,decode).  To set this option, change only:

     h/local.h:
          Remove the first three characters of line 19. Do not change  line
          14.

All other options should not be changed.

5.  Absolute pathnames

     Absolute pathnames  are  mainly  concentrated  in  "h/path.h"  and  in
"*/Makefile".   However,  some  pathnames  could  not  be  parameterized so
easily.  Read this chapter very carefully to see if any changes are  neces-
sary  for your installation.  For each pathname we will give all the places
that should be modified if changes are required.  We start  with  the  easy



                              April 15, 1980





                                   - 7 -


ones, that do not require any recompilation of the sources.

     Many pathnames are defined in exactly two places: in "h/path.h" and in
exactly one of "*/Makefile".  Recompilation of the sources is not necessary
if any of these are changed.  We give all these pathnames together with the
Makefile that contains their definition.

     EM1_PATH = /usr/bin/em1; see misc/Makefile
          Calling program for EM-1 interpreters
     PEM_PATH = /usr/lib/pc_pem; see pem/Makefile
          Compiler proper.
     PEMI_PATH = /usr/lib/pc_pem.out; see pem/Makefile
          Ditto, interpreted version.
     OPT_PATH = /usr/lib/pc_opt; see opt/Makefile
          EM-1 optimizer.
     PDP_PATH = /usr/lib/pc_pdp; see pdp/Makefile
          EM-1 to PDP-11 translator.
     ENC_PATH = /usr/lib/pc_encode; see misc/Makefile
          Readable to compact EM-1 code.
     ENCI_PATH = /usr/lib/pc_encode.out; see misc/Makefile
          Ditto, interpreted version.
     DEC_PATH = /usr/lib/pc_decode; see misc/Makefile
          Compact to readable EM-1 code.
     DECI_PATH = /usr/lib/pc_decode.out; see misc/Makefile
          Ditto, interpreted version.
     LIB_PATH = /usr/lib/pc_makelib; see misc/Makefile
          Make EM-1 library modules.
     ASS_PATH = /usr/lib/pc_ass; see ass/Makefile
          EM-1 assembler/loader.
     RT0_PATH = /usr/lib/pc_rt0.o; see libem/Makefile
          Startoff for compiled programs.
     FRT0_PATH = /usr/lib/pc_frt0.o; see libem/Makefile
          Ditto, for programs using reals.
     BSS_PATH = /usr/lib/pc_bss.o; see libem/Makefile
          Trailer for compiles programs.
     LIBEM_PATH = /usr/lib/pc_emlib.a; see libem/Makefile
          Library of EM-1 instructions for compiled programs.
     LIBPR_PATH = /usr/lib/pc_prlib.a; see libpr/Makefile
          Pascal run time support for compiled programs.
     EM1PR_PATH = /usr/lib/em1_pr.a; see libpr/Makefile
          Ditto for interpreted programs.
     TABLES_PATH = /etc/em1_tables; see etc/Makefile
          Describes EM-1 instructions.
     INFO_PATH = /etc/pc_info; see etc/Makefile
          Help file.
     ERR_PATH = /etc/pc_errors; see etc/Makefile
          Pascal compiler error messages.
     INT_DIR = /usr/lib/em1_int; see int/Makefile
          Directory containing binaries + sources of EM-1 interpreter.

The following pathnames give the names  of  standard  UNIX  programs,  that
should  exist  on  your  installation.  These pathnames are only defined in
"h/path.h" and modification of these pathnames does not require any  recom-
pilation.



                              April 15, 1980





                                   - 8 -


     AS_PATH = /bin/as
          UNIX assembler.
     MV_PATH = /bin/mv
          Move command to move new interpreters to their destination.
     LD_PATH = /bin/ld
          UNIX loader.
     CPP_PATH = /lib/cpp
          C preprocessor (UNIX version 7 only).

A few pathnames are only defined in exactly  one  of  "*/Makefile".   Their
modification does not require any recompilation.

     NEWS_PATH = /etc/pc_news; see etc/Makefile
          Latest news about Pascal.
     PC_PATH = /usr/bin/pc; see misc/Makefile
          Calling program for compilation of Pascal programs.
     DEBUG_PATH = /usr/bin/edebug; see misc/Makefile
          Program to debug interpreted programs.

Some programs have to create temporary files, notably the program 'pc'  for
temporary  files  during  compilation,  the  EM-1 assembler/loader 'ass' to
prevent large incore data structures, and the Pascal run time  library  for
Pascal  programs  that use local files.  Program 'pc' creates the temporary
files in

     TMP_DIR = /usr/tmp; see h/path.h

This  pathname  can  be  changed  without  any  recompilation.   The   EM-1
assembler/loader  'ass'  and  the  Pascal  run time library use the routine
tmpfil() to create invisible temporary files.  This routine tries the  fol-
lowing  directories in this order: "/usr/tmp", "/tmp" and ".".  If not suc-
cessful an error message is produced ('write error'  or  'rewrite  error').
If  these  directory  names  are  inappropriate, tmpfil() has to be recoded
(some constants have to be changed) and the programs and libraries have  to
be recompiled.  Sources are found in:

        ass/ass80.c
        libpr/csrc_pr.a, module opn.c
        libpr/esrc_pr.a, module opn.e
        libpr/ssrc_pr.a, module opn.s

Another built-in pathname is the name of the run time error message file:

     RTERR_PATH = /etc/pc_rterrors

This pathname should be changed in four files:

        h/path.h
        etc/Makefile
        libpr/esrc_pr.a, module fat.e, line 11
        libpr/ssrc_pr.a, module fat.s, 18 lines from the end

If the source libraries are updated you should give the  following  command
to recompile:



                              April 15, 1980





                                   - 9 -



        cd libpr; make bootI bootC

The last problem is formed by the usual abbreviation of library  pathnames.
The library name "-lxxx" is expanded by the standard UNIX loader 'ld' to

        /lib/libxxx.a

or, if not found, to

        /usr/lib/libxxx.a

In conformity with this convention  the  following  library  pathnames  are
defined:

     LIBPC_PATH = /usr/lib/libpc.a; see libpc/Makefile
          Library with several external Pascal routines.
     LIBMON_PATH = /usr/lib/libmon.a; see libmon/Makefile
          Library with system call routines.

A  similar  convention  is  used   for   libraries   used   by   the   EM-1
assembler/loader.  This program expands "-lxxx" to

        /lib/em1_xxx.a
        /usr/lib/em1_xxx.a

If  not  appropriate,  change  the  routine  libname()  on  line   184   in
"ass/ass00.c".   Recompile  afterwards.   The following pathnames should be
changed as well:

     EM1PC_PATH = /usr/lib/em1_pc.a; see libpc/Makefile
          Library with several external Pascal routines,  interpreted  ver-
          sion.
     EM1MON_PATH = /usr/lib/em1_mon.a; see libmon/Makefile
          Library with system call routines, interpreted version.

6.  Testing Pascal-VU

     After all the preparations, described in the  previous  chapters,  are
performed  successfully,  you  are now ready to install Pascal-VU.  To give
you some confidence in the distributed software, we have provided some test
programs,  written  in  Pascal.   These programs are found in the directory
"test".  Try these tests before you proceed with installation by typing the
following command in the working directory:

        make testI

The output should be as follows:









                              April 15, 1980





                                  - 10 -



        cd test; rm -f pc; ln ../misc/pcboot pc
        cd test; rm -f em1; ln ../misc/em1boot em1
        cd test; make testI
        pc t1.p; em1
        Program t1: 20 tests completed.Number of errors = 0
        pc t2.p; em1
        Program t2: 21 tests completed.Number of errors = 0
        pc t3.p; em1 e.out f1 f2 f3 f4 f5 f6
        Program t3:  6 tests completed.Number of errors = 0
        pc t4.p; em1
        Program t4:  8 tests completed.Number of errors = 0
        rm -f e.out f?
        cd test; rm -f pc em1

This tested the interpreted version of the four test programs.  Each of the
55  test procedures contain numerous subtests.  The compiled version can be
tested by typing:

        make testC

The output should be as follows:

        cd test; rm -f pc; ln ../misc/pcboot pc
        cd test; make testC
        pc -C -f t1.p; a.out
        Program t1: 20 tests completed.Number of errors = 0
        pc -C -f t2.p; a.out
        Program t2: 21 tests completed.Number of errors = 0
        pc -C -f t3.p; a.out f1 f2 f3 f4 f5 f6
        Program t3:  6 tests completed.Number of errors = 0
        pc -C -f t4.p; a.out
        Program t4:  8 tests completed.Number of errors = 0
        rm -f a.out f?
        cd test; rm -f pc

If any errors occur, you must try to  isolate  the  failing  tests.   There
might be some problems with the precision of floating point operations.  If
any other error occurs, you should try to find and  solve  the  problem  as
described in the chapter on troubleshooting.

     Note that the compilation speed of these tests is slowed down  consid-
erably, because the interpreted version of the compiler is used.  The tests
take about 20 minutes.

7.  Installation of Pascal-VU

     If none of the tests detects any errors, you may proceed with  instal-
lation.  At this point you should be able to write into all the directories
mentioned in all of the absolute pathnames.  Change to the  working  direc-
tory and type:

        make cpI




                              April 15, 1980





                                  - 11 -


The output should be as follows:

        cd misc; make pc em1
        rm -f path.h; ln ../h/path.h path.h
        cc -O -c pc.c
        rm -f path.h
        as -o printf.o printf.s
        cc -n -o pcnew pc.o printf.o
        rm -f path.h; ln ../h/path.h path.h
        cc -O -c em1.c
        rm -f path.h
        cc -n -o em1 em1.o printf.o
        cd misc; make cpI
        cp pcnew /usr/bin/pc
        cp em1 /usr/bin/em1
        cp edebug /usr/bin/edebug
        cp pc_makelib /usr/lib/pc_makelib
        cp pc_decode.out /usr/lib/pc_decode.out
        cp pc_encode.out /usr/lib/pc_encode.out
        rm -f pcboot em1boot
        rm -f pcnew em1 edebug pc_makelib
        rm -f pc_decode.out pc_encode.out
        cd ass; make cpI
        cp pc_ass-n /usr/lib/pc_ass
        rm -f pc_ass-? *.o
        cd opt; make cpI
        cp pc_opt-n /usr/lib/pc_opt
        rm -f pc_opt-? *.o
        cd libpr; make cpI
        cp em1_pr.a /usr/lib/em1_pr.a
        rm -f em1_pr.a
        cd pem; make cpI
        cp pc_pem.out /usr/lib/pc_pem.out
        rm -f pc_pem.out
        cd etc; make cpI
        cp em1_tables /etc/em1_tables
        cp pc_errors /etc/pc_errors
        cp pc_info /etc/pc_info
        cp pc_news /etc/pc_news
        cp pc_rterrors /etc/pc_rterrors
        cd int; make all
        rm -rf /usr/lib/em1_int
        mkdir /usr/lib/em1_int
        cp em.s ../h/local.s ?+ ?- /usr/lib/em1_int
        em1 -i
        em1 -i +r
        em1 -i +t
        em1 -i +rt
        rm -f em1??????

All the files necessary for Pascal  programs  to  be  interpreted  are  now
installed.  If compilation to PDP-11 code is also required, then type:

        make cpC



                              April 15, 1980





                                  - 12 -


The output should be as follows:

        cd misc; make cpC
        cp pc_decode /usr/lib/pc_decode
        cp pc_encode /usr/lib/pc_encode
        rm -f pc_decode pc_encode *.o
        cd pem; make cpC
        cp pc_pem-n /usr/lib/pc_pem
        rm -f pc_pem-?
        cd pdp; make cpC
        cp pc_pdp-n /usr/lib/pc_pdp
        rm -f pc_pdp-? *.o
        cd libpr; make cpC
        cp pc_prlib.a /usr/lib/pc_prlib.a
        rm -f pc_prlib.a
        cd libem; make cpC
        cp pc_emlib.a /usr/lib/pc_emlib.a
        cp pc_rt0.o /usr/lib/pc_rt0.o
        cp pc_frt0.o /usr/lib/pc_frt0.o
        cp pc_bss.o /usr/lib/pc_bss.o
        rm -f pc_emlib.a pc_rt0.o pc_frt0.o pc_bss.o

All the programs and files needed to compile standard Pascal  programs  are
now  installed.   Two extra libraries, however, are available.  Precompiled
versions of these libraries are not available.  Installation is possible by
typing in the working directory:

        make libI

The output should be as follows:



























                              April 15, 1980





                                  - 13 -



        cd libpc; make cpI
        ar x esrc_pc.a
        sh -v Compall_e
        pc -L arg.e
        .
        .
        .
        pc -L uwrite.e
        Mklib_e
        ar: creating em1_pc.a
        rm -f *.e *.l
        cp em1_pc.a /usr/lib/em1_pc.a
        rm -f em1_pc.a
        cd libmon; make cpI
        ar x esrc_mon.a
        sh -v Compall_e
        mv access.e access.c; cc -P access.c; mv access.i acc....
        .
        .
        .
        pc -L zerrno.e
        Mklib_e
        ar: creating em1_mon.a
        rm -f *.e *.l *.c
        cp em1_mon.a /usr/lib/em1_mon.a
        rm -f em1_mon.a

Now type:

        make libC

The output should be as follows:
























                              April 15, 1980





                                  - 14 -



        cd libpc; make cpC
        ar x ssrc_pc.a
        sh -v Compall_s
        as -o arg.o arg.s
        .
        .
        .
        as -o uwrite.o uwrite.s
        Mklib_s
        ar: creating libpc.a
        rm -f *.s *.o
        cp libpc.a /usr/lib/libpc.a
        rm -f libpc.a
        cd libmon; make cpC
        ar x ssrc_mon.a
        sh -v Compall_s
        as -o access.o ../h/local.s access.s
        .
        .
        .
        as -o zerrno.o zerrno.s
        Mklib_s
        ar: creating libmon.a
        rm -f *.s *.o
        cp libmon.a /usr/lib/libmon.a
        rm -f libmon.a


8.  Recompiling within the working tree.

     If errors are detected or if you modified the sources  for  any  other
reason, you may wish to recompile the affected source before a working ver-
sion of Pascal-VU is installed.  The keywords 'bootI' or 'bootC',  whatever
is  appropriate, may be used as arguments to 'make' in the directory of the
modified sources.  If changes are more globally, you might try the sequence

        make boot0 bootI bootC

in the working directory.  This command recompiles the entire  system  from
scratch.   It  takes  several  hours.  The output listings are too bulky to
include in this document.

9.  Documentation

     The directory "distr" contains  two  subdirectories:  "distr/doc"  and
"distr/man".   Manual  pages for Pascal-VU can be copied to "/usr/man/man?"
by the following commands:

        cd distr/man
        make cp


Several documents are provided:



                              April 15, 1980





                                  - 15 -



        ref.doc: the Pascal-VU reference manual
        em1.doc: a description of the EM-1 machine architecture
        val.doc: the results of running the Pascal Validation Suite
        pdp.doc: description of the EM-1 to PDP-11 code translator


These can be copied to "/usr/doc/pc" by typing:

        cd distr/doc
        mkdir /usr/doc/pc
        make cp


The Validation Suite is a collection of  more  than  200  Pascal  programs,
designed  by  Brian  Wichmann and Arthur Sale to test Pascal compilers.  We
are not allowed to distribute it, but you may request a copy from

        Richard J. Cichelli
        A.N.P.A.
        1350 Sullivan Trail
        P.O. Box 598
        Easton, Pennsylvania 18042
        USA


10.  Troubleshooting

     We only can give you some hints.  If you used  the  binaries  straight
from  the  distribution  tape  and discovered some errors, you might try to
recompile all sources on your installation.  The keyword 'cmp' can be  used
as  argument  to make in the individual directories to compare new binaries
with the ones installed.

     If 'pc' gives messages like:

        fatal error nn in xxx. Call an expert for help

then the program xxx died due  to  signal  nn.   A  created  core  file  is
automatically  removed  by  'pc',  unless  the  '-t'  option is given. This
preserves all intermediate files, the core files as  well.   Some  possible
signals are:

illegal instruction; nn=4
     This may be caused by the lack of floating point hardware,  while  the
     HARDWARE_FP  option  is  turned on.  An 11/40 type floating point unit
     will not work, because it uses different opcodes.

bad system call; nn=12
     Might be caused by different system calls on your  installation.   For
     standard Pascal programs only the following system calls are required:
     exit(1), read(3), write(4), open(5), close(6),  creat(8),  unlink(10),
     lseek(19),  getpid(20)  and ioctl(54).  The system calls unlink, lseek
     and getpid are not used by the  Pascal  programs  that  are  used  for



                              April 15, 1980





                                  - 16 -


     recompilation of the sources.

If any other fatal error occurs, like segmentation violation (nn=11) or bus
error  (nn=10), you must test the backup routine of your UNIX kernel to see
if it works properly.  Of course, this is  only  necessary  for  processors
that lack SSR1.

     This distribution kit assumes the presence of the following UNIX util-
ities:  cc, as, ld, sh, make, ar, mv, ln, rm, cp, mkdir and cmp.  Moreover,
they must be upwards compatible with UNIX version 7.

     If you do not succeed in solving the problems, you can visit, write or
phone

        Johan Stevenson,
        Wiskundig Seminarium,
        Vrije Universiteit,
        de Boelelaan 1081,
        Amsterdam,
        The Netherlands.
        phone: 020-5482410 from inside The Netherlands,
               31-20-5482410 from outside The Netherlands.


If you would appreciate receiving bug reports, send us your address.   How-
ever,  this  does  not  imply  any  commitment on our part to maintain this
software.

Good luck.




























                              April 15, 1980


