The following components are included in the installation package:
<install-dir>/doc/ccompindex.htm
The paper, Optimizing Applications with the Intel C++ and Fortran Compilers for Windows* and Linux*, explains how to use the Intel compilers to optimize for the Pentium 4 and Itanium processors and is available at http://www.intel.com/software/products/compilers/ . Additional information on the Intel Software Development Products is available at http://www.intel.com/software/products/ .
<install-dir>/doc/ccompindex.htm
Intel C++ Compiler for Itanium-Based Applications
The Intel C++ Compiler for Itanium-based applications contains the
following components:
<install-dir>/doc/ccompindex.htm
Compiler Drivers
The C compiler driver, icc
,
determines the language to use based
on the filename extension. However, when compiling preprocessed
files (*.i
), the icc
driver
assumes the C language, whereas the C++ driver, icpc
, assumes the C++ language. It is recommended to use the C++ compiler driver for C++ applications. Both the C (icc) and C++ (icpc) compilers always link against the C++ libraries for both C and C++ applications, consistent with previous releases.
ecc
to icc
, and
ecpc
to icpc
to be consistent with the
IA-32 compiler driver names. The old driver names are currently supported, but are deprecated.
/usr/lib/crt1.o: In function `_start':
/usr/lib/crt1.o(.text+0x18): undefined reference to `main'
icc: Command line error: no files specified; for help type "icc -help"
However, as executables no longer contain the location of the Intel shared libraries, you need to specify the location of the shared libraries. Any of the following techniques can be used to do this:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:<install-dir>/lib
.
ldconfig
system utility. Note: this requires root user privileges to run.
<install-dir>/bin/icc.cfg
error while loading shared libraries: libcprts.so.5: cannot open shared object file: No such file or directory
, you need to apply one of the 3 methods listed above to set the location of the Intel shared libraries.
The Intel processors code-named "Prescott" are a new generation of IA-32 processors. These processors support a new "SSE3" instruction set, which can improve performance of vectorized loops containing complex data types, float-to-integer conversions, and horizontal adds.
The Intel C++ Compiler 8.0 for Linux adds the ability to optimize
for this new processor generation including the new -xP
or -axP
options that allows the compiler to generate
new instructions and intrinsics for this processor, inline assembly,
and support for manual CPU dispatch with "future_cpu_10"
.
For further details, please consult the Optimization sections in the Intel C++ Compiler User's Guide.
The new -cxxlib-gcc
option allows you to
build your applications using the C++ run-time provided
by gcc. The gcc C++ run-time includes the libstdc++
standard C++ header files, library
and language support. When this option is specified,
these components are used instead of the libcprts standard
C++ headers, library, and libcxa and libunwind C++ language
support provided with the Intel Compiler.
When your applications are compiled and linked with the
-cxxlib-gcc
option, the resulting C++ object files,
libraries, and executables can interoperate with C++
object files, libraries, and executables generated by gcc 3.2.
This means that third party C++ libraries built with gcc 3.2
will work with C++ code generated by the Intel Compiler.
__GNUC__, __GNUC_MINOR__, and
GNUC_PATCHLEVEL__
macros. If you do not want
these macros to be defined, you can specify the
-no-gcc
option.
Additionally, this version of the Intel C++ Compiler
for Linux uses the C headers shipped with the version
of Linux you are running on, with the exception of
two small substitute headers used only by the Itanium
compiler for Itanium applications. Also, the -cxxlib-gcc
switch now compiles the Gnu C++ library headers if you use the
-ansi
language mode.
By default, the same path (conditional code)
in the headers will be used as is used by gcc 3.2,
with two exceptions; The Intel Compiler 8.0
pre-defines -D__NO_INLINE__
and
-D__NO_STRING_INLINES
. Note, these
pre-defines have no impact on interoperability with gcc 3.2.
The GNU C++ min/max operators are now implemented. See http://gcc.gnu.org/onlinedocs/gcc/Min-and-Max.html for additional information.
The following new gcc attributes have been implemented:
A large number of gcc built-in functions have been implemented in version 8.0 of the Intel C++ Compiler. The gcc built-in functions are documented at http://gcc.gnu.org/onlinedocs/gcc/Other-Builtins.html. Refer to the Intel C++ Compiler User's Guide for the list of supported gcc built-in functions.
-ansi
switch has been updated-ansi
switch has been updated to be compatible with the
gcc command line option of the same name.
The Intel compiler can support stricter conformance of
semantics to ISO C and C++ and this is implemented under the
-strict_ansi
command line option.
CPATH , C_INCLUDE_PATH , CPLUS_INCLUDE_PATH
-I
options.
DEPENDENCIES_OUTPUT , SUNPRO_DEPENDENCIES
The Intel C++ Compiler for Linux now supports both automatic and manual precompiled header processing. Under the right circumstances, the use of this new feature can dramatically improve compilation time. Please see the User Guide for additional details.
To use automatic precompiled header processing
add -pch
to your compile options. The
first compilation may take slightly longer as it
creates a .pchi
file. Subsequent
compiles will use the .pchi
file
and can be potentially much faster.
> icc -c -pch file1.cpp
"file1.cpp": creating precompiled header file "file1.pchi"
> icc -c -pch file1.cpp
"file1.cpp": using precompiled header file "file1.pchi"
If disk space is an issue you could reduce the number
of precompiled headers to one. To do this you could
create a new header file common.h and include all of
your important headers as illustrated in the example below.
common.h:
#include "myheader1.h"
#include "myheader2.h"
#include <iostream>
In each source file include common.h
followed by #pragma hdrstop
file1.cpp:
#include "common.h"
#pragma hdrstop
#include "otherheader1.h"
file2.cpp:
#include "common.h"
#pragma hdrstop
#include "otherheader2.h"
Compiling:
> icc -c -pch file1.cpp
"file1.cpp": creating precompiled header file "file1.pchi"
> icc -c -pch file2.cpp
"file2.cpp": using precompiled header file "file1.pchi"
Note that only one precompiled header is created. This produces most of the compile time improvement with a smaller amount of disk usage.
-ip
and -ipo
options-ip
and the
-ipo
options. Some information about variables will now be
available (although values may not be completely accurate due to
optimizations).
-Wbrief
print brief one-line diagnostics
-Wcheck
enables diagnostics about non-portable constructs
-Wp64
enables 64-bit porting specific warnings-fpstkchk
libguide
can only be dynamically linkedlibguide
, can potentially
cause performance issues that are hard to debug. 8.0
compilers will link libguide
dynamically regardless
of the command line options.
The Intel Compilers code coverage tool can be used in a number of ways to improve development efficiency, reduce defects, and improve application performance. When applied to the profile of the application on its test space, the tool can be used to measure the overall quality of testing based on the coverage information. Similarly, when applied to the profile of a performance workload, the code-coverage information indicates how well the workload exercises the application's critical code. High coverage of performance-critical modules is essential to taking full advantage of the profile-guided optimizations that Intel Compilers offer. The tool also provides an option, useful for both coverage and performance tuning, through which the users can display the dynamic execution count of each basic block of the application. Lastly, the coverage tool provides the ability to compare the profile of two different runs of the application. This feature can be used to find the portion of the application's code that is not covered by the application's tests but is exercised when the application is used outside the test space, such as by a customer.
The Intel Compilers code-coverage tool is supported on Intel Architecture 32-bit and the Itanium Processor Family on both Windows and Linux and seamlessly supports C, C++, and Fortran.
The Intel Compilers test-prioritization tool is supported on Intel Architecture 32-bit and the Itanium Processor Family on both Windows and Linux and seamlessly supports C, C++, and Fortran.
Please refer to the following link for additional details: http://www.intel.com/software/products/compilers/techtopics/pgt.htm .
.il
) during
interprocedural optimization (IPO).il
file generated by IPO will have a version number.
The compiler will only accept .il
files with matching
versions. The version numbers will be automatically
generated and updated as part of the build process.
-nostdlib
on the command
line or as a result of calling the linker directly rather than from the
Intel C++ Compiler driver.
The Intel C++ Compiler uses two routines _intel_fast_memcpy
and _intel_fast_memset
to perform memcpy and memset operations
that are not macro expanded to __builtin_memcpy
and
__builtin_memset
in the source code. These are
found in libirc
. If you use the gcc
compiler to link your application
or if you directly call the linker, ld
, you might find these unresolved
symbols. For this reason, Intel recomends using the Intel C++ Compiler
for linking, using the same compiler options used during the compilation
phase. However, if you see these as undefined externals, either add -lirc
to your link line, or change your includes so that memcpy
and
memset
will be macro expanded to the builtin forms and recompile.
The Intel C++ Compiler for IA-32 based applications calls a routine intel_proc_init
from the main routine of any program to ensure that the processor is correctly
set up. This routine is also found in libirc
. These routines used further
entry points from glibc
, so -lirc
needs to be placed before
-lc
on your command line.
gcc
behavior.
Const data will be placed in a read only data section and string
literals will be placed in the read-only section as well section.
Applications that depend on the old behavior will need to use the
new compiler option, -fwritable-strings
, added in 8.0 release.
The 7.1 release of the Itanium compiler places all dimensioned
constants and string literals in a writable data section. Starting
with 8.0 release, the default behavior will change and will match
the gcc behavior. In 8.0, dimensioned const data will be placed
in a read only data section and string literals will be placed in
the read-only section by default. Applications that depend on the
old behavior will need to use the new compiler option,
-fwritable-strings
, added in 8.0 release.
The option -fwritable-strings
is a gcc compatible option
that will cause string literals to be places in a writable data section.
It is provided for backward compatibility for applications that rely
on writing to strings.
-O3, -ipo
and -openmp
, may require substantially
larger amounts of RAM. The installation script of the Intel C++ Compiler uses the system utility RPM to install files. Note, both RPM 4.0.2 and RPM 4.1 have a limitation, please see Known Limitations below for details.
Note: The license for your Intel C++ Compiler for Linux 6.0.1 or 7.1 will work with the 8.0 compiler provided your support services have not expired.
Here is how to setup the license file before installation.
.lic
". /opt/intel_cc_80/licenses/
untar
the compiler package in a directory to which you have write access.> untar -xvf l_cc_p[c]_8.0.xxx.tar
> untar -zxvf l_cc_p[c]_8.0.xxx.tar.gz
> source ./install.sh
Intel Compiler for 32-bit applications
if you're
installing on an IA-32 system or Intel Compiler for Itanium architecture
if you're
installing on an Itanium-based systemLinux Application Debugger
-U --replacefiles
are recommended
to force the update of existing files. The default installation directory
is /opt/intel_cc_80/
for the Intel C++ Compiler, and
/opt/intel_idb_xx/
(xx: is the idb version number,
run "idb -V
" for the version) for the Intel Debugger.
'x'
to exit the install
script. (install.sh)
creates compiler environment
script files (iccvars.sh/ idbvars.sh)
that set these
variables. It is strongly recommended that you add those script files into
your login script (.login
file). So once the variables are set
in the ".login"
file there is no need to run the script files
for each session.
Source the script to setup the compiler environment:
> source <install-dir>/bin/iccvars.sh(.csh)
> source <install-dir>/bin/idbvars.sh(.csh)
The installation program also creates compiler configuration files named
<install-dir>/bin/icc.cfg
on an IA32 system or
an Itanium-based system
that contain common settings for all compilations.
You can edit these files to add additional default options. Note, if you
install a compiler update package, you need to save the configuration file if you
have modified it to another filename so that the installation doesn't overwrite
your modified file.
Please register for support after you install this product. See Technical Support for registration instructions.
<compiler-install-dir>/bin/uninstall.sh
/opt/intel_cc_80/bin/uninstall.sh
<debugger-install-dir>/bin/uninstall.sh
/opt/intel_idb_73/bin/uninstall.sh
Installation Warning for RPM 4.0.2 and RPM 4.1
RPM 4.0.2 cannot install to a non-default directory. This
has been resolved in RPM 4.0.3. RPM 4.1 cannot install to a non-default
directory. This has been resolved in RPM 4.11 to 4.2.
Note about installing the Intel Debugger version 7.3
When installing the Intel Debugger version 7.3 for
IA-32 or Itanium-based applications from the Intel C++
Compiler 8.0 package, if the Intel Debugger
version 7.1 or 7.2 is already installed
on the system, it will be upgraded to the Intel Debugger
version 7.3.
NPTL-based pthreads library in Red Hat* Linux 9
Some threaded (including OpenMP) applications may encounter problems
when linked with the new NPTL-based pthreads library introduced in
Red Hat Linux 9. In some cases, this may be worked around by setting
the environment variable LD_ASSUME_KERNEL=2.4.19
, which
results in the use of the previous pthreads library version without NPTL.
FLEXlm license daemon
The FLEXlm license daemon is not currently supported on systems
running Red Hat Linux 9 or Red Hat Enterprise Linux* 3.0. This daemon
is only needed if floating licenses are in use; in this case, the license server should be
installed on a system running some other supported operating system.
There is no effect on typical users with single user licenses,
which do not require a server.
OpenMP Limitations
POSIX threaded programs that require a large stack size may not run
correctly on some versions of Linux because of hard-coded stack size
limits in some versions of the Linux POSIX threads libraries.
These limits also apply to OpenMP programs (-openmp
) and automatically
generated parallel programs (-parallel
) with the Intel compilers, because
the Intel compilers use the POSIX threads library to implement OpenMP
based and automatically generated parallelism. Threaded programs that exceed the
stack space limit usually experience segmentation violations or addressing
errors.
To avoid these limitations, please use a version of
glibc built with the FLOATING_STACKS
parameter
defined, typically version 2.2.4 or later for both IA-32 and Itanium Processor
Family. Then use the ulimit -s ....
command to
set the maximum shell stack size to an explicit large value (units of KBytes)
and also set the KMP_STACKSIZE
environment
variable to the needed thread stacksize in bytes. A shell stacksize limit of
unlimited does not work - it causes a fixed hard limit to be imposed. Note, in
the bash shell, ulimit -s
can be used to set a
large maximum stack size only once. In the C shell (csh),
ulimit -stacksize
can be used to reset the maximum
stacksize repeatedly. The default values for KMP_STACKSIZE
have been increased to 2 MB for IA-32 and 4 MB for Itanium-based systems.
This solution has been tested on glibc version 2.2.4-13 for IA-32 and glibc 2.2.4-19 for Itanium Processor Family as found in the RedHat 7.2 Linux distribution. For glibc 2.2.4-13 on IA-32, the shared version of the POSIX threads library must be used, (there should not be a -static flag in the compiler .cfg file or on the command line).
Use of Profile Guided Optimization along with OpenMP may substantially
increase the execution time for the generation of the profile (.dyn
file). This is a known issue which is being addressed. The use of
profile guided optimization in conjunction with OpenMP is not recommended
for this version of the Intel C++ Compiler.
Compile time slow down when using both -g
and inlining
There will be an increase in compile time when -g
is used together with inlining. Inlining can happen if the user
specifies -ipo, -ip
or compiles a C++/C99
program
at option levels -O1
or above. This is due to the
generation of debug information. For many applications, this
combination of compiler options will not increase compile
time or compile-time memory use.
Please click on the appropriate link below to see additional notes and
known limitations in the latest version of the compiler.
Registration Center
".
For information about the Intel C++ Compiler's Users Forums, FAQ's, tips and tricks, and other support information, please visit: http://support.intel.com/support/performancetools/c/linux/. For general support information please visit http://www.intel.com/software/products/support/.
Submit
" button.
I Accept
" button.
Go
" button next to the "Product
" drop-down list.
Submit Issue
" link in the left navigation bar.
Development Environment (tools,SDV,EAP)
" from the
"Product Type
" drop-down list.
Intel C++
Compiler, Linux*
" from the "Product Name
" drop-down list.
> uname -a
> rpm -qa | grep glibc
rpm
installed, use the command below: > ls /lib/libc*
Get the Intel C++ Compiler's Package ID with the following commands:
> icc -V -c
And copy the "Package ID" (e.g. l_cc_p[c]_8.0.xxx
) from
the output into the corresponding Premier Support field. Please include
any other specific
information that may be relevant to helping us to reproduce and address
your concern.
<package ID>_README
(e.g. l_cc_p[c]_8.0.xxx_README
), available for download from Intel
Premier Support, https://premier.intel.com, to see which issues have
been resolved in the latest version of the compiler.
The documentation is installed in the
<install-dir>/doc
(default /opt/intel_cc_80/doc
)
directory. An HTML index document can be found at
<install-dir>/doc/ccompindex.htm
(default /opt/intel_cc_80/ccompindex.htm
).
An interactive HTML-based training tutorial Enhancing Performance with Intel Compilers
is also available from links in the documentation index. This provides a
tutorial on using compiler options that help you optimize your application for IA-32 and Itanium-based systems and describes the Itanium Assembler.
The Intel® Debugger Manual can be found from
the Intel® Debugger directory (default
/opt/intel_idb_xx/doc
(xx: is the idb version number,
run "idb -V
" for the version)).
The document Intel® C++ Compiler User's Guide is now organized into separate parts:
For information on the GNU glibc C language library, documentation can be obtained from the Linux OS vendor or from the GNU web site, www.gnu.org.
icc
(1) manpage provides a
list of command-line options and related information for the
icc
and icpc
compiler commands. To display
the icc
(1) manpage, type the
following command after you set up your environment by using a
source command to execute the <install-dir>/bin/iccvars.*sh
file:
$ man icc
The man
command provides single keys or key combinations
that let you scroll through the displayed content, search for a string,
jump to a location, and perform other functions. For example, type the
z
to view the next screen or w
to view the
previous screen. To obtain help about the man command, type the
h
key; when you are done viewing help, type the q
key to return to the displayed manpage. To search, type /
character followed by the search string (/string
) and
press Enter. After viewing the man command text, type q
to
return to the shell command prompt.
xpdf
utility (provides search capability), the gv command,
or install
Adobe Acrobat Reader*. On some Linux distributions, using mozilla will display PDF files using a PDF helper.
Edit --> Preferences --> Navigator --> Applications --> new
Description: Portable Document Format
MIMEType: application/pdf
Suffixes: pdf
Application: acroread %s
Another method to configure acroread is to add
the following entry in the file .mailcap
in your home
directory:
application/pdf; acroread %s
Depending on your version of
the Netscape browser, you might need to disable (turn OFF) the "Automatically
load images" option or the browser will
freeze when you open the HTML documentation files, this means that you
will then need to click on the images in the documentation if you want to
see them while paging through the documentation with the browser. Turn
OFF this option by clicking on: Edit-->Preferences-->Advanced-->Automatically
load images and other data types
.
Copyright (C) 2001 ~ 2003 Intel Corporation. All Rights Reserved.