Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ pc(1) — Duplix 4.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

prof(1)

gprof(1)

adb(1)

dbx(1)

ld(1)

cc(1)

f77(1)

cc(1)

PC(1)  —  Unix Programmer’s Manual

NAME

pc − Pascal compiler

SYNOPSIS

pc [ options ] files

DESCRIPTION

Pc is an optimizing ISO and/or ANSI/IEEE Pascal compiler.  Pc accepts several types of arguments:

Arguments whose names end with ‘.p’ are Pascal source programs; they are compiled and left in a ‘.o’ file in the working directory. 

Arguments whose names end with ‘.f’ are Fortran 77 source programs; they are compiled and left in a ‘.o’ file in the working directory. 

The f77(1) and cc(1) commands are normally used for Fortran and C programs.  When multi-lingual programs need to be compiled, you can use any one of the three commands (cc, pc, or f77). 

Arguments whose names end with ‘.s’ are assembly language source programs; they are assembled and left in a ‘.o’ file in the working directory. 

If you compile and link a single source file, pc deletes the ‘.o’ file. 

Pc creates ‘.s’ files for each module only if the user compiles with the −S option. 

OPTIONS

Pc accepts the following options.  Additional options are supported by ld(1). 

−20 Generates code which assumes that a 68020 is present. To maintain compatibility with old code, the alignment rules are not changed unless you specify -X134. This alignment forces longwords to 32 bit boundaries,. 

−c Compiles to the ‘.o’ level only; does not link. 

−C Compiles code to perform runtime checks, verifies assert calls, and initializes all variables to zero as in pi. 

−f Generates code which assumes the presence of a 68881 coprocessor.  By default many of the functions supported by the 68881 will be inline as well.  Use -Z129 if you want a transcendental call to go to the routine instead.  The −f option does not support profiling. 

−g Generates BSD style debugger information in the assembly file, for use with a debugger such as dbx(2). 

−ga Generates a stack frame for every routine, regardless of need. 

−Idir ‘#include’ files whose names do not begin with ‘/’ are always sought first in the directory of the file argument, then in directories named in −I options, then in /usr/include. 

−o output Names the final output file output. With this option, pc leaves the file ‘a.out’ undisturbed.  This does not apply to assembly output. 

−O Performs various speed optimizations, such as moving constant expressions out of loops. Generally this makes your programs somewhat larger; if their performance is not loop bound, they may be slower as well. 

−O0 Disables all user accessible optimizations.  This option is useful for porting code to the ISI compilers because the generated code looks similar to PCC.  Additionally it may be useful for minimizing compilation time. 

−O2 Allows the optimizer to assume that memory locations do not change except by explicit stores.  That is, the optimizer is guaranteed that no memory locations are I/O device registers that can be changed by external hardware and no memory locations are being shared with other processes which can change them asynchronously with respect to the current process.  This compile time option must be used with extreme caution (or not at all) in device drivers, operating systems, shared memory environments, and when interrupts (or UNIX signals) are present. 

−p Generates profiling code, in a manner similar to cc(1), and link the code with routines which support prof(1).  However, −p does not support programs compiled with the −f (floating point) option. 

−pg Generates profiling code similar to −p, but links with a more involved profiling mechanism which supports gprof(1).  Like the −p option, −pg does not support profiling for programs compiled with the −f (floating point) option. 

−R Makes initialized variables part of the text segment; passed on to as. 

−S Compile the named C programs and leaves the assembler-language output on corresponding files suffixed ‘.s’. 

−w Suppresses warning messages. 

−Xn Where n is an integer constant.  Turns on option number n. There are numerous options available for such things as signed bit fields, short return types, etc.  You can find descriptions of these options in Section 8 of the UNIX Compiler Guide:  C, Pascal, FORTRAN 77. 

−Zn Turns off option number n.  This is the reverse of the X option.  This option is useful for turning off options this are on by default. 

FILES

file.pPascal source file
/bin/asassembler
/usr/lib/pcomPascal compiler
/usr/lib/libc.aUNIX standard I/O library
/usr/lib/libc_p.aprofiling UNIX standard I/O library
/usr/lib/libmc.aUNIX standard I/O library for the 68020/68881
/usr/lib/libpc.aPascal I/O library with math intrinsics
/usr/lib/libpc_p.aprofiling Pascal I/O library with math intrinsics
/usr/lib/libm.a intrinsic floating point math library
/usr/lib/libm_p.aprofiling intrinsic floating point library
/usr/lib/libmm.a68020/68881 intrinsic floating point math library
/usr/lib/libSkyc.aUNIX standard I/O library compiled for Sky FFP
/usr/lib/libSkym.aintrinsic math library for Sky FFP
/usr/lib/Skycrt0.o∗startup code for the Sky FFP
/usr/lib/gcrt0.o∗profiling startup code
/lib/mcrt0.o∗profiling startup code
mon.outfile produced for analysis by prof(1)
gmon.outfile produced for analysis by gprof(1)

SEE ALSO

Kathleen Jensen and Niklaus Wirth, Pascal User Manual and Report, Springer-Verlag, 1978
American National Standard Pascal Computer Programming Language, IEEE/John Wiley-Interscience, 1983
UNIX Compiler Guide:  C, Pascal, FORTRAN 77
as(1)
, prof(1), gprof(1), adb(1), dbx(1), ld(1), cc(1), f77(1), cc(1)

DIAGNOSTICS

The diagnostics produced by the Pascal compiler are intended to be self-explanatory and similar to those produced by the BSD pc compiler.  Occasional messages may be produced by the assembler or loader. 
 

4th Berkeley Distribution  —  5 October 1987

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