Content-type: text/html
Manpage of pgcc
pgcc
Section: User Commands (1)
Updated: June 2003
Index
NAME
pgcc - The Portland Group Compiler Technology ANSI and K&R C compiler
SYNOPSIS
pgcc
[
-#
]
[
-###
]
[
-B
]
[
-Bdynamic
]
[
-Bstatic
]
[
-C
]
[
-c
]
[
-c9x
]
[
-Dname[=def] ]
[
-dryrun
]
[
-E
]
[
-fast
]
[
-fastsse
]
[
-flags
]
[
-fpic
]
[
-G
]
[
-g
]
[
-g77libs
]
[
-help
]
[
-Idirectory
]
[
-i
]
[
-Kflag
]
[
-Ldirectory
]
[
-l library
]
[
-M
]
[
-MD
]
[
-Mpgflag
]
[
-m
]
[
-mp
]
[
-O[level]
[
-o file
]
[
-P
]
[
-pc
]
[
-Q[dir | path | produce | option ]
]
[
-ql
]
[
-qp
]
[
-Rdirectory
]
[
-r
]
[
-rc file
]
[
-S
]
[
-s
]
[
-shared
]
[
-show
]
[
-silent
]
[
-time
]
[
-tp
{px | p5 | p6 | piii | piv | p7 | athlon | athlonxp | k7 | k8-32 | k8-64 }
]
[
-Uname
]
[
-uname
]
[
-V
]
[
-v
]
[
-Wpass,option[,option...]
]
[
-w
]
[
-Xlevel
]
[
-x
]
[
-Ypass,directory
]
[
-y
]
sourcefile...
DESCRIPTION
pgcc is the interface to the Portland Group Compiler Technology (PGI)
C compiler for X86 or AMD64 processors.
It invokes the C compiler, assembler, and
linker with options derived from its command line arguments.
pgcc
bases its processing on the suffixes of the files it is passed.
Files whose names end with
.c
are considered to be C source files.
They are preprocessed, compiled and assembled.
The resulting object file is placed in the current directory.
Files whose names end with
.s
are considered to be X86 or AMD64 assembly language files.
They are assembled and the resulting object file is placed in the current
directory.
Files whose names end with
.o
are taken as object files, and are passed directly to the linker if linking
is requested.
Files whose names end with
.a
are taken as
ar
libraries. No action is performed on
.a
files unless linking is requested.
Files whose names end with
.f
or
.F
are considered to be Fortran source files
and are compiled by the Fortran compiler.
Files not ending in
.o,
.s,
.i,
.c,
.f,
.F,
.ipo,
or
.a
are taken as object files and passed to the linker (if linking is requested)
with a warning message.
If a single C program is compiled and linked with one
pgcc
command, then the intermediate object and assembly files are deleted.
OPTIONS
When source files are compiled using any of the
-g,
-mp,
-Mconcur,
-Mipa,
-Mpf,
or
-Mprof
options, the
same option(s) should be used when using
pgcc
to link the objects.
- -#
-
Display the invocations of the compiler, assembler, and linker.
These invocations are the command lines created by
pgcc.
- -###
-
Display invocations of the compiler, assembler and linker, but do
not execute them.
- -B
-
Allow C++-style comments in source code; these begin with the
characters '//' and continue to the end of the current line. Such
comments are stripped unless you specify the -C option.
- -Bdynamic
-
Passed to the linker to specify dynamic binding
- -Bstatic
-
Passed to the linker to specify static binding
- -C
-
Preserve comments in preprocessed C source files.
- -c
-
Skip the link step; compile and assemble only.
- -c9x
-
Use the C9x standard as the C source language
- -Dname[=def]
-
Define
name
to be
def
in the preprocessor. If
def
is missing, it is assumed to be empty. If
the = sign is missing, then
name
is defined to be the string 1.
- -dryrun
-
Use this option to display the invocations of the compiler,
assembler, and linker but do not execute them.
- -E
-
Preprocess each
.c
file and send the result to standard output. No compilation, assembly, or
linking is performed.
- -fast
-
Chooses generally optimal flags for the target platform. Equivalent to
"-O2 -Munroll=c:1 -Mnoframei -Mlre".
- -fastsse
-
Chooses generally optimal flags for an X86 or AMD64 machine that supports
the SSE (Pentium 3/4, AthlonXP/MP, Opteron, Athlon64) and SSE2 (Pentium 4,Opteron, Athlon64) type instructions. Equivalent to
"-fast -Mscalarsse -Mvect=sse -Mcache_align -Mflushz".
- -flags
-
Display valid driver options and additional driver help
information.
- -fpic
-
(Linux only) Instructs the compiler to generate
position-independent code which can be used to create shared object
files (dynamically linked libraries).
- -fPIC
-
Equivalent to -fpic. Provided for compatibility with other compilers.
- -g
-
Generate symbolic debug information. This also sets the optimization
level to zero, unless a
-O
switch is present on the command line. Symbolic debugging may give
confusing results if an optimization level other than zero is selected.
Using
-O0
the generated code
will be slower than code generated at other optimization levels.
- -g77libs
-
A link-time option which allows object files generated by GNU
g77
(or
gcc
) to be linked in to
pgcc
main programs.
- -help
-
Displays options recognized by the driver on the standard output.
- -Idirectory
-
Add
directory
to the compiler's search path for include files. For include files
surrounded by
< >,
each
-I
directory is searched followed by the standard area. For include files
surrounded by " ",
the directory containing the file containing the
#include
directive is searched, followed by the
-I
directories, followed by the standard area.
- -Kflag
-
Requests that the compiler provide special compilation semantics.
The permitted
flags
are:
-
- ieee
-
Perform
float
and
double
divides in conformance with the IEEE 754 standard. This is done by replacing
the usual in-line divide algorithm with a subroutine call, at the expense of
performance. The default algorithm produces results that differ from the
correctly rounded result by no more than 3 units in the last place.
Also, on some systems, a more accurate math library may be linked if
-Kieee
is used during the link step.
- noieee
-
Use the in-line divide algorithm, link in the non-IEEE libraries
if available, and disable underflow traps.
- PIC
-
Equivalent to -fpic. Provided for compatibility with other compilers.
- pic
-
Equivalent to -fpic. Provided for compatibility with other compilers.
- trap=option[,option]...
-
Controls the behavior of the X86 or AMD64 processor when floating-point
exceptions occur. Possible options include fp,
align (ignored), inv, denorm, divz, ovf,
unf, and inexact. -Ktrap is only processed when
compiling a main function/program. The options inv, denorm,
divz, ovf, unf, and inexzct correspond to
the X86 or AMD64 processor's exception mask bits invalid operation,
denormalized operand, divide-by-zero, overflow, underflow, and
precision, respectively. Normally, the X86 or AMD64 processor's exception
mask bits are on (floating-point exceptions are masked - the processor
recovers from exceptions and continues). If a floating-point exception
occurs and its corresponding mask bit is off (or "unmasked"), execution
terminates with an arithmetic exception (C's FPE signal).
-Ktrap=fp is equivalent to -Ktrap=inv,divz,ovf.
- -Ldirectory
-
Change the default directory in which the linker searches for libraries to
directory.
If the linker supports this option, then the option is passed to the linker;
otherwise, the driver replaces the default library area with
directory
and uses it when constructing library path names.
Note that a library search path can be established using this option
only if the linker supports such functionality.
- -llibrary
-
Load the library
liblibrary.a
from the standard library directory. If the linker supports this option;
then the option is passed to the linker.
The library name is constructed and the full library
path is passed to the linker. See the
-L
option above.
- -M
-
Generate a list of make dependences and print them to stdout.
- -MD
-
Generate a list of make dependences and print them to
the file file.d, where file is the root name of the file
under compilation.
- -Mpgflag
-
See the description for the -Mpgflag options on the
following pages.
- -m
-
Display a link map on the standard output.
- -mp
-
Interpret OpenMP pragmas to explicitly parallelize
regions of code for execution by multiple threads on a
multi-processor system. Most OpenMP pragmas as well as
the SGI parallelization pragmas are supported. See Chapter 11
of the
PGI User's Guide
for more information on these pragmas.
- -O[level]
-
Set the optimization level.
If
-O
is not specified, then
the default level is
1
if
-g
is not specified, and
0
if
-g
is specified.
If a number is not supplied with
-O
then the optimization level is set to
2 .
The optimization levels and their meanings are as follows:
-
- 0
-
A basic block is generated for each C statement. No scheduling is done
between statements. No global optimizations are performed.
- 1
-
Scheduling within extended basic blocks is performed.
Some register allocation is performed. No global optimizations
are performed.
- 2 3 4
-
All level 1 optimizations are performed. In addition, traditional scalar
optimizations such as induction recognition and loop invariant motion are
performed by the global optimizer.
- -o file
-
Use
file
as the name of the executable program, rather then the default
a.out.
- -P
-
Preprocess each file and leave the output in
a file named file.i for each file named file.c.
- -pc
-
The X86 or AMD64 architecture implements a floating-point stack using 8 80-bit
registers. Each register uses bits 0-63 as the significand,
bits 64-78 for the exponent, and bit 79 is the sign bit. This
80-bit real format is the default format (called the extended format).
When values are loaded into the floating point stack they are automatically
converted into extended real format.
The precision of the floating point stack can be controlled, however,
by setting the precision control bits (bits 8 and 9) of the floating control
word appropriately. In this way, the programmer can explicitly
set the precision to standard IEEE double using 64 bits, or to single
precision using 32 bits.
The default precision setting is system dependent.
If you use -pc to alter the precision setting for a routine,
the main program must be compiled with the same value for -pc.
The command line option -pc val lets the
programmer set the compiler's precision preference. Valid values for
val are:
32 single precision
64 double precision
80 extended precision
Operations performed exclusively on the floating point stack using
extended precision, without storing into or loading from
memory, can cause problems with accumulated values within the extra 16
bits of extended precision values.
This can lead to answers, when rounded, that do not match expected results.
- -ql
-
Enables line-level profiling. See -Mprof=lines
- -qp
-
Enables profiling. See -Mprof=func
- -Rdirectory
-
(Linux only) Passed to the linker; always search
directory for shared object files when running the generated
executable.
- -r
-
Passed to the linker; generate a re-linkable object file.
- -rc rcfile
-
Specifies the name of a driver startup configuration file.
If
rcfile
is a full pathname, then use the specified file.
If
rcfile
is a relative pathname, use the file name as found in in the
$DRIVER directory.
- -S
-
Skip the assembly and link steps. Leave the output from the compile step in
a file named file.s for each file named file.c
or file.f.
- -s
-
Passed to the linker; strip symbol table information.
- -shared
-
(Linux only) Passed to the linker. Instructs the linker to generate
a shared object file (dynamically linked library).
- -show
-
Produce driver help information describing the current driver
configuration.
- -silent
-
Do not print warning messages. Same as -Minform=severe
- -time
-
Print execution times for the various compilation steps.
- -tp
-
Specify the type of the target processor; possibilities are
-tp px
for blended code generation that will work on any x86-compatible
processor,
-tp p5
for Pentium processors,
-tp p6
for Pentium Pro/II processors,
-tp piii
for Pentium III processors,
-tp p7 | -tp piv
for Pentium 4 processors,
-tp athlon
for AMD Athlon processors,
-tp athlonxp | -tp k7
for AMD AthlonXP and AthlonMP processors.
-tp k8-32
for AMD64 Opteron processors running 32-bit applications, and
-tp k8-32
for AMD64 Opteron processors running 64-bit applications.
The default in the absence of the
-tp
flag is to compile for the type of CPU on which the compiler
is running.
- -Uname
-
Remove any initial definition of
name
in the preprocessor. The only names predefined by the preprocessor itself
are the standard ANSI C predefined macros. The driver may predefine other
names (see the
following description for
the
-Mnostddef
option). Since all
-D
options are processed before all
-U
options, the
-U
option override
-D
options.
NOTE: ANSI C predefined macros can be defined and undefined on the command
line, but not with
#define
and
#undefine
directives in the source.
- -uname
-
Passed to the linker; generate undefined reference.
- -V
-
Display version messages and other information.
- -v
-
Verbose mode. Print out the command line for each tool before it is
executed.
- -Wpass,option[,option...]
-
Pass the
options
to the specified
pass.
Each comma-delimited
option
is passed as a separate argument.
The passes are:
0
for the compiler,
a
for the assembler,
i
for the IPA linker,
and
l
for the linker.
- -w
-
Do not print warning messages.
- -Xlevel
-
Specify the degree of ANSI C conformance.
The level argument can be either a or c { a | c }.
-
- a
-
Use ANSI mode.
The compiled language conforms to all new ANSI features.
- c
-
Use the conformance mode.
The compiled language conforms to ANSI C,
but warnings may be produced about some extensions.
- s
-
The compiled language conforms to K&R C.
- t
-
The compiled language conforms to K&R C.
The compiler may produce warnings for semantics where ANSI C and K&R C conflict.
- -Ypass,directory
-
Look in
directory
for pass
pass,
rather then in the standard area. The passes are:
-
- 0
-
Search for the
pgc
executable in
directory.
- a
-
Search for the assembler executable in
directory.
- C
-
Search for the compiler library in
directory.
- i
-
Search for the IPA linker in
directory.
- l
-
Search for the linker executable in
directory.
- S
-
Search for the startup object files in
directory.
- L
-
If the linker supports the
-YL
option, then pass the option
-YL,directory
to the linker. Otherwise, use
directory
as the standard library location.
- U
-
If the linker supports the
-YU
option, then pass the option
-YU,directory
to the linker. Otherwise this option is ignored.
- I
-
Set the compiler's standard include directory to
directory.
The standard include directory is set to a default value by the driver and
can be overridden by this option.
- -y
-
Arguments are passed to the linker.
- -Mpgflag
-
Request PGI-specific actions from the compiler. Many of
pgflags
optionally begin with
no
(e.g.
[no]list).
If the default of such an option is the
no
variant,
this is indicated by
no
appearing in bold italics as in
[no]list.
The permitted
pgflags
are:
-
- anno
-
Produce annotated assembly files, where source code is intermixed with
assembly language.
-Mkeepasm
or
-S
must be used as well.
- [no]asmkeyword
-
(Don't) allow the
asm
keyword in C source code. The format is:
asm("<text>")
- [no]bounds
-
Enable (disable) array bounds checking.
Bounds checking is not applied to a subscripting pointer.
- [no]builtin
-
(Don't) Do compile with math subroutine builtin support,
which causes selected math library routines to be inlined.
- cache_align
-
Align unconstrained data objects of size greater than or equal to
16 bytes on cache-line boundaries.
An unconstrained object is a variable or array that is not a member
of an aggregate structure or common block, is not allocatable, and is not
an automatic array.
- chkfpstk
-
Check for internal consistency of the X86 or AMD64 FP stack in the
prologue of a function and after returning from a function
or subroutine call. If the PGI_CONTINUE environment variable
is set, the stack will be automatically cleaned up and execution
will continue. There is a performance penalty associated with the
stack cleanup. If PGI_CONTINUE is set to verbose, the stack will
be automatically cleaned up and execution will continue after a warning
message is printed.
- chkstk
-
Check the stack for available space upon entry to and before
the start of a parallel region. Useful when many private variables
are declared.
- concur[=option[,option,...]]
-
Instructs the compiler to enable auto-concurrentization of
loops. If
-Mconcur
is specified, multiple processors will be used to execute
loops which the compiler determines to be parallelizable.
When linking, the
-Mconcur
switch must be specified or
unresolved references will occur. The
NCPUS
environment variable controls how many processors will
be used to execute parallelized loops.
The options can be one or more of the following:
-
- altcode[:n]
-
Instructs the parallelizer to generate alternate scalar
code for parallelized loops. If
altcode
is specified without arguments, the parallelizer
determines an appropriate cutoff length and generates
scalar code to be executed whenever the loop count is
less than or equal to that length. If
altcode:n
is specified, the scalar altcode is executed whenever
the loop count is less than or equal to
n.
- noaltcode
-
If
noaltcode
is specified, the parallelized version of the loop is
always executed regardless of the loop count.
- dist:block
-
Parallelize with block distribution. Contiguous blocks of
iterations of a parallelizable loop are assigned to the
available processors.
- dist:cyclic
-
Parallelize with cyclic distribution. The outermost
parallelizable loop in any loop nest is parallelized.
If a parallelized loop is innermost, its iterations
are allocated to processors cyclically. For example,
if there are 3 processors executing a loop, processor
0 performs iterations 0, 3, 6, etc; processor 1
performs iterations 1, 4, 7, etc; and processor 2
performs iterations 2, 5, 8, etc.
- cncall
-
Loops containing calls are safe to parallelize. Also,
no minimum loop count threshold must be satisfied before
parallelization will occur, and last values of scalars are
assumed to be safe.
- noassoc
-
Disables parallelization of loops with reductions.
- coff
-
Generate a COFF formatted object
- [no]dalign
-
(Don't) align doubles in structures on 8-byte
boundaries.
-Mnodalign
may lead
to data alignment exceptions.
- [no]llalign
-
(Don't) align long longs or INTEGER*8 in structures or common
blocks on 8-byte
boundaries.
-Mnollalign
s the default, and this is a change with release 4.0. Releases prior to 4.0 aligned long longs on 8-byte boundaries.
- [no]depchk
-
(Don't) assume that potential data dependencies exist.
-Mnodepchk
may result in
incorrect code; the
-Msafeptr
switch provides a less dangerous way to accomplish the same thing.
- dwarf1
-
Generate DWARF1 debug information with -g
- dwarf2
-
Generate DWARF2 debug information with -g. This is default.
- dollar,char
-
Set the character used to replace dollar signs in names to be
char.
Default is an underscore (_).
- elf
-
Generate ELF formatted object
- extract=[option[,option,...]]
-
Run the subprogram extraction phase to prepare for inlining.
The
-o filename
option or
=lib:filename
option must be used
with this switch to name an extract library.
See
-Minline
for more details on inlining.
-
- subprogram[,subprogram]
-
A non-numeric option not containing a period is assumed to be
the name of a subprogram to be extracted.
- name:subprogram[,subprogram]
-
Specifies the name of a subprogram or subprograms to be extracted.
- lib:directory
-
Specifies the name of a directory to contain the extracted subprograms;
this directory will be created if it does not exist.
The directory may also be specified with the
-o directory option.
- [size:]number
-
A numeric option is assumed to be a size.
Functions containing
number
or less statements are extracted.
If both
number
and
function
are specified, then functions matching the given name(s)
or
meeting the size requirements, are extracted.
- levels:<n>
-
Extracts n times to gain multiple levels of inlining
- fcon
-
Treat non-suffixed floating point constants as
float,
rather than
double.
This may improve the performance of single-precision code.
- [no]flushz
-
Set SSE MXCSR register to flush-to-zero mode
- [no]fptrap
-
-Mnofptrap
performs the semantics of
-Knoieee
(use in-line divide, link in non-IEEE libraries if available, and
disable underflow traps)
and disables floating point traps.
- [no]func32
-
Align functions on 32 byte boundaries
- info[=option[,option,...]]
-
Emit useful information to stderr. The options are:
-
- time | stat
-
Emit compilation statistics.
- loop
-
Emit information about loops.
This includes information about vectorization and loop unrolling.
- inline
-
Emit information about functions extracted and inlined.
- ipa
-
Emit information about the InterProcedural Analyzer (IPA).
- sym
-
Emit symbol names as comments in assembly file.
- all
-
All of the above.
- inform=level
-
Specify the minimum level of error severity that the compiler
displays during compilation.
-
- fatal
-
instructs the compiler to display fatal error messages.
- severe
-
instructs the compiler to display severe and fatal error messages.
- warn
-
instructs the compiler to display warning, severe and fatal error messages.
- inform
-
instructs the compiler to display all error messages (inform,
warn, severe and fatal).
- inline[=option[,option,...]]
-
Pass options to the function inliner. The options are:
-
- [lib:]filename.ext
-
An option containing a period is assumed to be an inline library created by
a previous
-Mextract
option.
If
lib:
is specified, no period is necessary.
Functions from the specified library are inlined.
If no library is specified, functions are extracted from a temporary
library created during an extract prepass.
- except:<func>
-
Specifies which functions should not be inlined.
- [name:]function
-
A non-numeric option not containing a period is assumed to be a function name.
If
name:
is specified, what follows is always the name of a function.
- [size:]number
-
A numeric option is assumed to be a size.
Functions containing
number
or less statements are inlined.
If both
number
and
function
are specified, then functions matching the given name(s)
or
meeting the size requirements, are inlined.
- levels:number
-
number
of levels of inlining are performed.
The default is 1.
- ipa[=option[,option,...]]
-
Pass options to the InterProcedural Analyzer (IPA).
If no option list is specified, then it is
equivalent to
-Mipa=const.
The options are:
-
- const | noconst
-
Enable or disable propagation of constants across procedure calls.
- ptr
-
Instructs the IPA to perform pointer disambiguation
across procedure calls.
- align
-
Instructs the IPA to recognize when pointer targets
are all cache-line aligned, allowing better SSE code
generation.
- arg
-
Instructs the IPA to remove arguments replaced
by
-Mipa=ptr,const.
- localarg
-
Externalizes local variables for use with
-Mipa=arg
- vestigial
-
Instructs the IPA to eliminate functions that are not called.
- globals
-
Instructs the IPA to optimize references to globals when not
used in procedure calls.
- pure
-
Pure function detection.
- inline
-
Instructs the IPA to inline functions.
- levels:<n>
-
n is the maximum number of levels ipa should attempt to inline, if approproate.
- fast
-
Equivalent to
-Mipa=const,globals,localarg,ptr,vestigial.
- safe
-
When the whole call tree is not available to the IPA,
declares that unknown procedures do not call back into
the known procedures and do not change global variables.
- collect
-
Used to run the first phase of IPA, the data collection,
without generating code.
- ipofile
-
Save the IPA information in a ".ipo" file instead of the
default of appending the information to the object file.
- noerror
-
Disables the default behavior of producing an error if
recompilation is needed.
- rm
-
The default. Removes stale object files at IPA link time.
- norm
-
Overrides the
-Mipa=rm
process.
- keepasm
-
Keep the assembly file for each C source file, but continue to assemble and
link the program. This is mainly for use in compiler performance analysis
and debugging.
- lfs
-
Link in the Large File Support routines available on
Linux versions later than Red hat 7.0 or SuSE 7.1.
This will support files from fortran I/O that are larger
than 2GB. Equivalent to -L$PGI/linux86/5.0/liblf .
- [no]list
-
(Don't) create a listing file.
- lre[=assoc | noassoc]
-
Perform Loop-carried redundancy elimination.
assoc | noassoc
Allow or not allow expression reassociation.
- mpi
-
(CDK only) -Mmpi inserts a -L$MPILIB -lfmpich -lmpich
into the link line, where $MPILIB is set in localrc
(if it's not set, the -L$MPILIB is left out).
The user can set the environment variables MPILIB
and MPILIBNAME to rename the directory and library name.
- neginfo=option[,option]...
-
Instructs the compiler to produce information on why certain
optimizations are not performed. Possible value for option
include concur and loop.
- noframe
-
Eliminate operations that set up a true stack frame pointer for
functions.
- nontemporal
-
Allow nontemporal move prefetching. Under -fastsse, -Mnontemporal
can sometimes be faster than -fastsse alone.
- noopenmp
-
When -mp is present, ignore the OpenMP pragmas.
- nosgimp
-
When -mp is present, ignore the SGI parallelization pragmas.
- nostddef
-
Do not predefine any macros to the preprocessor when compiling a C program.
The normal predefined macro is:
-Dunix.
- nostdinc
-
Do not search in the standard location for include files when those files are
not found elsewhere.
- nostdlib
-
Do not link in the standard libraries when linking a program.
- nostartup
-
Do not link in the usual startup routine. This routine contains the entry
point for the program.
- novintr
-
Do not generate vector intrinsic calls.
- nozerotrip
-
Removes the zero-trip test. Only use when all loops are known
to execute at least once.
- pf[=filename]
-
Invoke the Profile Feedback Analyzer (PFA). This should
be used in conjunction with the IPA.
Use
file
as the name of the PFA file rather than the default
- prof[=option[,option,...]]
-
Set profile options. Normally, the
-q
or
-p
switches are used for this;
however, on some systems, it is desirable to override the default method of
profiling. See the PGI profiler manual, or the system profiler manual, for
further information.
-
- func
-
Perform PGI-style function level profiling.
- lines
-
Perform PGI-style line level profiling.
- mpi
-
Use and link MPICH-style profiling (CDK Only).
- quad
-
Align large objects on quad-word boundaries.
- [no]reentrant
-
(Don't) enable optimizations that may result in code that
is not reentrant.
Even with
-reentrant ,
the code may still not be reentrant if it is improperly written
(e.g., SAVEd variables).
- safe_lastval
-
In the case where a scalar is used after a loop, but is not defined on
every iteration of the loop, the compiler does not by default parallelize
the loop. However, this option tells the compiler it safe to parallelize
the loop.
- safeptr[=option[,option,...]]
-
Override data dependence between C pointers and arrays.
This option must be used with care
since the potential exists for code to
be generated that will result in unexpected or incorrect results as is defined by
ANSI C. However, when used properly, this option has the potential to greatly enhance
the performance of code, especially floating point oriented loops.
Combinations of the
options
may be used and interact appropriately.
-
- dummy | arg
-
C dummy arguments (pointers and arrays) are treated with the same copyin/copyout
semantics as Fortran dummy arguments.
- auto
-
C local or auto variables (pointers and arrays) are assumed not to overlap or conflict
with other data objects and are independent.
- static
-
C static variables (pointers and arrays) are assumed not to overlap or conflict
with other data objects and are independent.
- global
-
C global or extern variables (pointers and arrays) are assumed not to overlap or conflict
with other data objects and are independent.
- scalapack
-
Add the Scalapack libraries. (CDK only)
- scalarsse
-
Utilize the SSE (Pentium 3, 4, AthlonXP/MP/64, Opteron) and SSE2
(Pentium 4/Athlon64/Opteron) instructions to
perform the operations coded. This assumes the user
has an assembler capable of interpreting SSE/SSE2
instructions, as in later versions of Linux.
This implies -Mflushz.
- schar
-
Specify signed
char
characters. Also see the -Muchar option.
- [no]single
-
(Don't) suppress the ANSI-specified conversion of
float
to
double
when passing arguments to a function with no prototype in scope.
-Msingle
may result in faster code when single precision is used a lot,
but is non-ANSI compliant.
- [no]signextend
-
(Don't) sign extend when a narrowing conversion overflows.
For example, when
-Msignextend
is in effect and an integer containing the value 65535 is
converted to a short, the value of the short will be -1.
This option is provided for compatibility with other compilers,
even though ANSI C specifies that the result of such conversions
are undefined.
-Msignextend
is the default.
- stabs
-
Generates limited stabs info. (Windows only)
- uchar
-
Treat plain
char
declarations as
unsigned char
declarations. Also see the -Mschar option.
- unroll[=option [,option...]]
-
Invokes the loop unroller.
This also sets the optimization level to 2 if the level is set to less than 2.
The option is one of the following:
-
- c:m
-
Instructs the compiler to completely unroll loops with a
constant loop count less than or equal to m, a supplied constant.
If this value is not supplied, the m count is set to 4.
- n:u
-
instructs the compiler to unroll u times, a loop which is
not completely unrolled, or has a non-constant loop count.
If u is not supplied, the unroller computes the number of times a
candidate loop is unrolled.
- nounroll
-
Instructs the compiler not to unroll loops.
- vect[=option[,option,...]]
-
Pass options to the internal vectorizer.
If no option list is specified, then
the following vector optimizations are used:
assoc,cachesize:262144,nosse. The vect options are:
-
- altcode:n
-
Instructs the vectorizer to generate alternate scalar code for vectorized
loops. If altcode is specified without arguments, the vectorizer determines
an appropriate cutoff length and generates scalar code to be executed
whenever the loop count is less than or equal to that length. If
altcode:n is specified, the scalar altcode is executed whenever the
loop count is less than or equal to n.
- noaltcode
-
If noaltcode is specified, the vectorized version of the loop is always
executed regardless of the loop count.
- assoc
-
Instructs the vectorizer to enable certain associativity conversions that
can change the results of a computation due to roundoff error.
A typical optimization is to change an arithmetic operation
to an arithmetic operation that is mathematically correct,
but can be computationally different, due to round-off error.
- noassoc
-
Instructs the vectorizer to disable associativity conversions.
- cachesize[:number]
-
Instructs the vectorizer, when performing cache tiling
optimizations, to assume a cache size of
number.
- prefetch
-
Instructs the vectorizer to search for loops, and where possible,
use the Pentium III or Athlon prefetch instructions.
- sse
-
Instructs the vectorizer to search for loops, and where possible,
use the Pentium III SSE and prefetch or the AthlonXP 3Dnow and prefetch instructions.
- nosse
-
Instructs the vectorizer not to use Pentium III SSE or prefetch or AthlonXP 3Dnow or prefetch instructions.
- idiom
-
Instructs the vectorizer to look for idioms that can be directly substitured with internal routines before performing vectorizing optimizations.
- noidiom
-
Instructs the vectorizer to not look for idioms, before performing vectorizing optimizations.
This is the default behavior.
FILES
- a.out
-
executable output file, UNIX
- a.exe
-
executable output file, Windows NT
- pgprof.out
-
PGPROF output file,
- file.a
-
library of object files
- file.c
-
C source file
- file.i
-
C source file after preprocessing
- file.ipa
-
InterProcedural Analyzer (IPA) file
- file.ipo
-
InterProcedural Analyzer (IPA) file
- file.o
-
object file
- file.s
-
assembler source file
Executables reside in
one of:
$PGI/linux86/5.0/bin,
or
$PGI/nt86/5.0/bin;
libraries and objects reside in
one of
$PGI/linux86/5.0/lib,
or
$PGI/nt86/5.0/lib;
PGI
is an environment variable that is set to the root of the compiler
installation directory. If
PGI
is not set, the default is
/usr/pgi
on UNIX systems and
C:/pgi
on Windows NT. Below, <target> is one of linux86,
or nt86
- $PGI/<target>/5.0/bin/pgc
-
C compiler
- $PGI/<target>/5.0/bin/pgcc
-
C compilation driver
- $PGI/<target>/5.0/lib/libc.a
-
C library
- $PGI/<target>/5.0/include
-
Include files for C library
- $PGI/<target>/5.0/bin/.pgccrc
-
Default driver startup configuration file
- $PGI/<target>/5.0/bin/.pgirc
-
Default driver startup configuration file
- $PGI/<target>/5.0/bin/linux86rc
-
Default driver startup configuration file
- $PGI/<target>/5.0/bin/nt86rc
-
Default driver startup configuration file
- $PGI/<target>/5.0/bin/pgcomprc
-
Default driver startup configuration file
- $PGI/<target>/5.0/bin/sharedrc
-
Default driver startup configuration file
SEE ALSO
pgCC, pgf77, pgf90, pghpf, pgprof,
pgdbg, and the PGI User's Guide.
DIAGNOSTICS
The compiler produces information and error messages as it translates the
input program. The linker and assembler may issue their own error messages.
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- OPTIONS
-
- FILES
-
- SEE ALSO
-
- DIAGNOSTICS
-
This document was created by
man2html using the manual pages.