<?xml version="1.0" encoding="UTF-8"?>
<!-- Generated on Wed, 25 Nov 2009 12:11:21 -0800 -->
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <atom:link href="http://software.intel.com/en-us/articles/intel-c-compiler-for-linux-kb/type/tips-and-techniques/feed/" rel="self" type="application/rss+xml" />
    <title>Intel Software Network articles feed</title>
    <link>http://software.intel.com/en-us/articles/intel-c-compiler-for-linux-kb/tips-and-techniques/</link>
    <description></description>
    <language>en-us</language>
    <item>
      <title>Compile moblin 2.1 kernel sources with Intel Compiler</title>
      <description><![CDATA[ <p>1.  Prepare for build</p>
<p>       a.  su into root.</p>
<p>       b.  Create a ~/.rpmmacros file containing:</p>
<p>       %_topdir %(echo $HOME)/rpmbuild</p>
<p>      %_smp_mflags -j3</p>
<p>      %__arch_install_post /usr/lib/rpm/check-rpaths /usr/lib/rpm/check-buildroot</p>
<p>      %_default_patch_fuzz 2</p>
<p>      #end of file</p>
<p>      fuzz=2 is critical to allow the 915 patches to merge correctly.</p>
<p>_smp_mflags -jN, N should be set to the number of processor cores on your build system</p>
<p>2.  Setup and do initial build.  Download the kernel source from a source repository:</p>
<p>(Used http://repo.moblin.org/moblin/releases/2.1/source/kernel-2.6.31.5-10.1.moblin2.src.rpm)</p>
<p>       a.  Extract the rpm:</p>
<p>       $ rpm -ivh kernel-2.6.31.5-10.1.moblin2.src.rpm</p>
<p>       b. Prepare and do initial build to rpm:</p>
<p>       $ cd rpmbuild/SPECS</p>
<p>       c. Remove lines 762 &amp; 763, 'BuildKernel %make_target %kernel_image menlow' &amp; 'BuildKernel %make_target %kernel_image ivi'</p>
<p>       $ rpmbuild -bc --target=i586 kernel.spec</p>
<p>       The previous step ensures you have the components to build successfully.</p>
<p>3.  Rebuild with gcc:</p>
<p>       $ cd rpmbuild/BUILD/kernel-2.6.31/linux-2.6.31</p>
<p>       $ make clean</p>
<p>       $ make bzImage</p>
<p>       $ make modules</p>
<p>       $ make modules_install</p>
<p>       $ make install </p>
<p>      Test the image on your netbook by rebooting the system and selecting the kernel at the grub screen.</p>
<p>Rebuild with Intel Compiler</p>
<p>1.  Perform step 1 in the previous section</p>
<p>2.  Setup Intel Compiler environment:</p>
<p>       a.  Set the compiler environment:</p>
<p>       $ source /opt/intel/Compiler/11.1/XXX/bin/ia32/iccvars_ia32.sh</p>
<p>       where XXX is the particular version you are using.</p>
<p>3.  Make source code modifications.</p>
<p>      a.  Modify include/linux/compiler-intel.h and add the following line at</p>
<p>the end of the file:</p>
<p>       #undef __compiler_offsetof</p>
<p>       b.  Modify arch/x86/include/asm/xor_32.h at line 843, change</p>
<p>       : "+r" (lines),</p>
<p>       To:</p>
<p>       : "+rm" (lines),</p>
<p>       This change is required because the code is written to work with gcc's assumption that the stack is 16 byte aligned (contrary to the ABI) and thus there is one additional register available.</p>
<p>c.  Add libirc_s.a to the link command by modifying Makefile at line 699.  Change:</p>
<p>       --start-group $(vmlinux-main) --end-group</p>
<p>       to:</p>
<p>       --start-group $(vmlinux-main) /opt/intel/Compiler/11.1/XXX/lib/ia32/libirc_s.a</p>
<p>--end-group</p>
<p>       d.  Modify arch/x86/include/asm/delay.h and remove the references to __bad_udelay and replace the calls to it with 0.</p>
<p>       e.  Modify include/linux/log2.h and remove the references to ____ilog2_NaN() and replace the calls to it with 0.</p>
<p>       f.  Modify line 47 of arch/x86/kernel/acpi/realmode/Makefile adding a reference to libirc_s.a as follows:<br />        WAKEUP_OBJS = $(addprefix $(obj)/,$(wakeup-y)) /opt/intel/Compiler/11.1/053/lib/ia32/libirc_s.a</p>
<p>        g.  Modify line 89 of arch/x86/boot/Makefile adding a reference to libirc_s.a as follows:<br />SETUP_OBJS = $(addprefix $(obj)/,$(setup-y)) /opt/intel/Compiler/11.1/053/lib/ia32/libirc_s.a</p>
<p>        h. Modify kernel/trace/trace_events.c by adding the following line of code (line 915) at the start of event_create_dir():<br />        if (call-&gt;system==NULL) return -1;<br />This change is due to a kernel issue where the source code makes alignment assumptions that are not enforced in the kernel source code.  This change is merely a workaround, not a fix for the real issue.</p>
<p>        i.  Modify the intelwrapper file documented at <a href="http://www.linuxdna.com/">www.linuxdna.com</a> and make the following changes:<br />          - Enable script to replace -march=i686 | -mtune=pentium3 | -mtune=generic with ‘'<br />          - Enable script to replace -O2 | -Os with ‘-O3 -ip -xSSE3_ATOM'<br />            Performance BKM: The goal of this option change is to enable higher performance.  Note that the default kernel options uses things such as -mnosse and -fno-omit-frame-pointer which can override the higher optimizations in some places.<br />          - Enable script to call gcc to compile drivers/net/wimax/i2400m/fw.c | lib/libcrc32c* | crypto/testmgr* - this is required because 11.1 does not yet support some instances of variable length arrays<br />          - Enable script to call gcc to compile arch/x86/boot/compressed/misc.c - issue with PIC in icc<br />          - Enable script to call gcc to compile drivers/block/spectra/ffsport.c - inline asm issue</p>
<p>4.  Start the build:</p>
<p>       $ cd &lt;build path&gt;/rpmbuild/BUILD/kernel-2.6.31/linux-2.6.31</p>
<p>       $ make clean</p>
<p>       $ make HOSTCC=intelwrapper CC=intelwrapper CONFIG_DEBUG_SECTION_MISMATCH=y KBUILD_MODPOST_WARN=n bzImage</p>
<p>       $ make HOSTCC=intelwrapper CC=intelwrapper CONFIG_DEBUG_SECTION_MISMATCH=y KBUILD_MODPOST_WARN=n modules</p>
<p>       $ make HOSTCC=intelwrapper CC=intelwrapper CONFIG_DEBUG_SECTION_MISMATCH=y KBUILD_MODPOST_WARN=n modules_install</p>
<p>       $ make HOSTCC=intelwrapper CC=intelwrapper CONFIG_DEBUG_SECTION_MISMATCH=y KBUILD_MODPOST_WARN=n install</p>
<p>The make install step will install the kernel and modify grub so that the kernel can be selected upon bootup.</p>
To build with other configurations, such as the mrst config:<br />cp configs/kernel-mrst.config .config and go to step 4.<br />
<div id="art_pre_template"><strong></strong></div> ]]></description>
      <link>http://software.intel.com/en-us/articles/compile-moblin-21-kernel-sources-with-intel-compiler</link>
      <pubDate>Wed, 18 Nov 2009 09:36:37 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/compile-moblin-21-kernel-sources-with-intel-compiler#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/compile-moblin-21-kernel-sources-with-intel-compiler</guid>
      <category>Intel® Atom™ Software Developer Community</category>
      <category>Intel C++ Tool Suite for MIDs</category>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
    </item>
    <item>
      <title>error 409 when building boost libraries 1.40.0 with Intel compiler</title>
      <description><![CDATA[ <p><strong>Problem : <br /></strong>When building boost libraries version 1.40.0 with Intel compiler 11.1.046, the compiler report error #409 like below:</p>
<blockquote>
<p>./boost/wave/cpplexer/re2clex/cpp_re2c_lexer.hpp(119): error #409: "boost::wave::cpplexer::re2clex::lexer&lt;IteratorT, PositionT&gt;::lexer(const IteratorT &amp;, const IteratorT &amp;, const PositionT &amp;, boost::wave::language_support)" provides no initializer for:<br />const member "boost::wave::cpplexer::re2clex::lexer&lt;IteratorT, PositionT&gt;::cache"<br />{<br />^<br />detected during:<br />instantiation of "boost::wave::cpplexer::re2clex::lex_functor&lt;IteratorT, PositionT&gt;::lex_functor(const IteratorT &amp;, const IteratorT &amp;, const PositionT &amp;, boost::wave::language_support) [with IteratorT=char *, PositionT=boost::wave::util::file_position_type]" at line 402<br />instantiation of "boost::wave::cpplexer::lex_input_interface *boost::wave::cpplexer::new_lexer_gen&lt;IteratorT, PositionT&gt;::new_lexer(const IteratorT &amp;, const IteratorT &amp;, const PositionT &amp;, boost::wave::language_support) [with IteratorT=char *, PositionT=boost::wave::util::file_position_type]" at line 52 of "libs/wave/src/instantiate_re2c_lexer.cpp"</p>
</blockquote>
<p><strong>Environment :</strong> <br /><br />Boost libraries version 1.40.0 for linux*<br />Intel C++ Compiler for linux, version 11.1.046<br /><br /><strong>Root Cause :</strong> <br />Need initializer for const variable cache defined in file cpp_re2c_lexer.hpp, line 107. Refer this article <a href="http://software.intel.com/en-us/articles/cdiag409">http://software.intel.com/en-us/articles/cdiag409</a> for details.<br /><br /><strong>Resolution : <br /></strong>This error no longer occurs with the Intel® C++ Compiler 11.1.059 for Linux*.  As a workaround as well, you can add an initializer for the const variable cache in file boost/wave/cpplexer/re2clex/cpp_re2c_lexer.hpp. For example:</p>
<pre name="code" class="cpp">template &lt;typename IteratorT, typename PositionT&gt;
inline
lexer&lt;IteratorT, PositionT&gt;::lexer(IteratorT const &amp;first, 
IteratorT const &amp;last, PositionT const &amp;pos, 
boost::wave::language_support language_) 
: filename(pos.get_file()), at_eof(false), language(language_),cache(token_cache&lt; typename lexer &lt; IteratorT, PositionT &gt;::string_type &gt;())
{
using namespace std; // some systems have memset in std
memset(&amp;scanner, '\0', sizeof(Scanner));
</pre>
<p> </p> ]]></description>
      <link>http://software.intel.com/en-us/articles/error-409-when-building-boost-libraries-1400-with-intel-compiler</link>
      <pubDate>Tue, 17 Nov 2009 19:21:42 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/error-409-when-building-boost-libraries-1400-with-intel-compiler#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/error-409-when-building-boost-libraries-1400-with-intel-compiler</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
    </item>
    <item>
      <title>Intel® C++ Compiler - Supported compiler versions</title>
      <description><![CDATA[ <!--CTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dt-->
<table border="0" cellpadding="0" cellspacing="15">
<tbody>
<tr>
<td class="bodycopy">
<p>Interactive support via <a href="/en-us/articles/performance-tools-for-software-developers-intel-premier-support">Intel® Premier Support</a> or the Intel User Forums is provided for the two most recent compiler major releases. Older compiler versions are not supported.</p>
<p>If you have any questions about this policy, contact <a href="/en-us/articles/performance-tools-for-software-developers-intel-premier-support">Intel® Premier Support</a> or post on the appropriate Intel User Forum.</p>
<p>The following compiler versions are currently supported:</p>
<ul>
<li>Intel® C++ Compilers 11.x</li>
<li>Intel® C++ Compilers 10.x</li>
</ul>
<p>Compiler updates for each major version are always made to the most current minor version.  The following compiler versions are being actively updated:<br /><br />
<ul>
<li>Intel® C++ Compiler 11.1</li>
<li>Intel® C++ Compiler 10.1</li>
</ul>
</p>
<p><strong>Note:</strong> Version 8.x or 9.x is no longer supported.</p>
</td>
</tr>
</tbody>
</table> ]]></description>
      <link>http://software.intel.com/en-us/articles/intel-c-compiler-supported-compiler-versions</link>
      <pubDate>Thu, 12 Nov 2009 16:31:42 -0800</pubDate>
      <comments>http://software.intel.com/en-us/articles/intel-c-compiler-supported-compiler-versions#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/intel-c-compiler-supported-compiler-versions</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
      <category>Intel® C++ Compiler for Mac OS X* Knowledge Base</category>
      <category>Intel® C++ Compiler for Windows* Knowledge Base</category>
    </item>
    <item>
      <title>Redistributable libraries for the Intel(R) C++ and Visual Fortran Compiler Professional Editions for Linux*</title>
      <description><![CDATA[ <p><strong class="sectionHeading">Overview<br /></strong><br />This article contains links to the redistributable installation packages for the Intel Compiler Professional Editions for Linux*. <br />The redistributable packages are for the end users who use applications that are built with Intel Compilers. Please note that there is one redistributable package for every compiler update. Make sure you download and install the one recommended by the application vendor. <br /><br /><strong><span class="sectionHeading">OS requirement for redistributable packages for Intel Compiler Professional Editions for Linux 11.1</span></strong></p>
<p><br />The supported Linux distributions are:</p>
<ul>
<li>Asianux* 3.0 </li>
<li>Debian* 4.0 </li>
<li>Fedora* 10 </li>
<li>Red Hat Enterprise Linux* 3, 4, 5 </li>
<li>SUSE LINUX Enterprise Server* 9, 10, 11 </li>
<li>TurboLinux* 11</li>
<li>Ubuntu* 9.04</li>
</ul>
<p>
<p><strong><span class="sectionHeading">Installation instructions<br /></span><br /></strong>First of all, use following command to untar the .tgz file: <br />    $tar -xzvf l_cprof_p_11.1.056_redist.tgz<br /><br />To start the installation, run following shell command: <br />    $. ./install.sh<br />The installation shell program (install.sh) of the redistributable package will guide you through the installation. You will need to accept the license and the installation will install all the libraries to the following directory. But you can change the installation directory. <br /><br />For the redistributable package of Intel C++ Compiler Professional Edition for Linux, the default installation directory is <br />    /opt/intel/Compiler/11.1/xxx/<br /><br />For the redistributable package of the Intel Fortran Compiler Professional Edition for Linux, the default installation directory is <br />    /opt/intel/Compiler/11.1/xxx/<br /><br /><strong><span class="sectionHeading">Links to the redistributable packages<br /></span><br /></strong>
<p>
<table border="1" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td width="295" valign="top"><b>Intel C++ Compiler for Linux<br />11.1.056 (update 2)</b> <br /><br /><a href="http://registrationcenter.intel.com/irc_nas/1583/l_cproc_p_11.1.056_redist.tgz">• Redistributable library package</a></td>
<td width="295" valign="top"><b>Intel Visual Fortran Compiler for Linux<br />11.1.056 (update 2)</b><br /><br />
<p><a href="http://registrationcenter.intel.com/irc_nas/1582/l_cprof_p_11.1.056_redist.tgz">• Redistributable library package</a></p>
</td>
</tr>
<tr>
<td width="295" valign="top"><b>Intel C++ Compiler for Linux update 3</b> <br /><br /><a href="http://registrationcenter.intel.com/irc_nas/1624/l_cproc_p_11.1.059_redist.tgz">• Redistributable library package</a></td>
<td width="295" valign="top"><b>Intel Visual Fortran Compiler for Linux update 3</b><br /><br />
<p><a href="http://registrationcenter.intel.com/irc_nas/1626/l_cprof_p_11.1.059_redist.tgz">• Redistributable library package</a></p>
</td>
</tr>
<tr>
<td width="295" valign="top">
<p><br />Currently we do not have redistributable packages for Intel® IPP, Intel® TBB, and Intel® MKL. When they're available, this article will be modified to include them.</p>
</td>
<td width="295" valign="top"><br />Currently we do not have redistributable packages for Intel® MKL. When available, this article will be modified.</td>
</tr>
</tbody>
</table>
</p>
<p><br /><br /><strong>References<br /><br /></strong><a href="http://software.intel.com/en-us/articles/redistribution-of-application-binaries-built-for-linux/">Redistribution of Application Binaries Built for Linux*</a></p>
</p>
</p>
<p>
<div></div>
</p> ]]></description>
      <link>http://software.intel.com/en-us/articles/redistributable-libraries-for-the-intelr-c-and-visual-fortran-compiler-professional-editions-for-linux</link>
      <pubDate>Wed, 14 Oct 2009 11:09:44 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/redistributable-libraries-for-the-intelr-c-and-visual-fortran-compiler-professional-editions-for-linux#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/redistributable-libraries-for-the-intelr-c-and-visual-fortran-compiler-professional-editions-for-linux</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
      <category>Intel® Fortran Compiler for Linux* Knowledge Base</category>
    </item>
    <item>
      <title>Build ffmpeg/ffmpeg-mt using Intel compiler on linux</title>
      <description><![CDATA[ <br />
<div id="art_pre_template"><b>Introduction : </b><br />FFmpeg is a complete, cross-platform solution to record, convert and stream audio and video. FFmpeg-mt is the multithreaded version of FFmpeg. Visit http://ffmpeg.org for more information.<br /><br /><b>Version : </b><br />I use the latest source from FFMPEG git and Intel C++ compiler 11.1.046 for linux.<br /><br /><br /><b>Obtaining Source Code : </b><br />Get the ffmpeg source:<br />  git clone git://git.ffmpeg.org/ffmpeg<br />  cd ffmpeg<br />  git clone git://git.ffmpeg.org/libswscale<br /><br />Get the ffmpeg-mt source:<br />  git clone git://git.gitorious.org/ffmpeg/ffmpeg-mt<br />  cd ffmpeg-mt<br />  git clone git://git.mplayerhq.hu/libswscale<br /><br /><strong>Build the application:<br /></strong>The build process for ffmpeg and ffmpeg-mt is similar.</div>
<div>1. go to the source code folder.</div>
<div>2. configure the build. Please use ./configure --help for more options. </div>
<div>   ./configure --prefix=/usr --enable-shared</div>
<div>3. Build with gcc compiler by default.</div>
<div>    make &amp; make install</div>
<div>4. To build with Intel compiler, use the following command after step 2.</div>
<div>    source /opt/intel/Compiler/11.1/046/bin/iccvars.sh ia32</div>
<div>    make CC=icc LD=icc</div>
<div>    make install</div>
<div>5. To build with more advanced options like "-ipo" using Intel compiler, we can use a wrapper to change build option. For example:</div>
<div>    1) make a new file with name intelwrapper, input the followings in the file:</div>
<div>            ICCFLAGS="$@ -ipo"</div>
<div>            echo "icc $ICCFLAGS"</div>
<div>            icc $ICCFLAGS</div>
<div>     2) add execution attribute for intelwrapper</div>
<div>            chmod 755 intelwrapper</div>
<div>     3) make CC=/bin/intelwrapper AR=xiar LD=icc<br />     4) make install</div>
<div>     </div> ]]></description>
      <link>http://software.intel.com/en-us/articles/build-ffmpegffmpeg-mt-using-intel-compiler-on-linux</link>
      <pubDate>Mon, 28 Sep 2009 02:31:21 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/build-ffmpegffmpeg-mt-using-intel-compiler-on-linux#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/build-ffmpegffmpeg-mt-using-intel-compiler-on-linux</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
    </item>
    <item>
      <title>Build boost libraries 1.40 for linux using Intel compiler</title>
      <description><![CDATA[ <strong>Introduction:<br /></strong>    Boost provides free peer-reviewed portable C++ source libraries. This KB introduces how to build boost libraries 1.40.0 using Intel compiler on linux. Please get the boost libraries source from <a href="http://www.boost.org/">http://www.boost.org/</a> . Please goto <a href="http://www.boost.org/doc/libs/1_40_0/more/getting_started/unix-variants.html">http://www.boost.org/doc/libs/1_40_0/more/getting_started/unix-variants.html</a> to read Boost getting started on linux for more details.<br /><br /><strong>Version:<br /></strong>The version of Boost used in this document is 1.40.0. The Intel compiler version is 11.1.046 for linux.<br /><br /><strong>Build Process:<br /></strong>1. Uncompress the Boost distribution into a directory, where it will create a boost_1_40_0 directory containing the distribution.<br />2. set up Intel compiler build environment, e.g.<br />    source /opt/intel/Compiler/11.1/046/bin/iccvars.sh ia32<br />3. Run the bootstrap.sh file with intel tool set.<br />    ./bootstrap.sh --prefix=/path/to/my/installation/folder --with-toolset=intel-linux<br />4. Run bjam and install.<br />    ./bjam install<br />You will find the header files and libraries in folder /path/to/my/installation/folder.<br /><br /><br /><br /><br /><br />
<div id="art_pre_template"><br /></div> ]]></description>
      <link>http://software.intel.com/en-us/articles/build-boost-libraries-140-for-linux-using-intel-compiler</link>
      <pubDate>Thu, 24 Sep 2009 02:33:14 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/build-boost-libraries-140-for-linux-using-intel-compiler#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/build-boost-libraries-140-for-linux-using-intel-compiler</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
    </item>
    <item>
      <title>Using icc to build x264</title>
      <description><![CDATA[ <br />
<div id="art_pre_template"><b>Introduction : </b><br />x264 is a free library for encoding H264/AVC video streams. For more details about x264, please refer to <a href="http://www.videolan.org/developers/x264.html">http://www.videolan.org/developers/x264.html</a> <br /><br /><strong>Gcc build:<br /></strong>    x264 uses gcc to build by default in linux OS. To build x264, extract the source to a local directory, e.g. x264.<br />1. goto x264 folder.<br />2. ./configure --prefix=/usr --enable-mp4-output --enable-pic --enable-shared<br />3. make &amp; make install<br /><br /><strong>Icc build:</strong><br />    You can use the same build process as gcc build. Before the configuration, you just need to set CC to icc.<br />1. export CC=icc<br />2. source /opt/intel/Compiler/11.1/xxx/bin/iccvars.sh ia32 to set the icc build environment for ia32.<br />2. ./configure --prefix=/usr --enable-mp4-output --enable-pic --enable-shared<br />3. make &amp; make install<br />     There will have some warnings during icc build. You can ignore it or you need to change the configure file to fix it. For example, change -O4 to -O3 in file for icc build.<br />      For better encoding performance, you can set the optimized options in CFLAGS environment before the configuration. For example, if your machine support SSE4.1, you can add option -xSSE4.1 to CFLAGS. <br /><br /><br /></div> ]]></description>
      <link>http://software.intel.com/en-us/articles/using-icc-to-build-x264</link>
      <pubDate>Wed, 23 Sep 2009 23:12:30 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/using-icc-to-build-x264#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/using-icc-to-build-x264</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
    </item>
    <item>
      <title>Changing Language Setting to see English on a Japanese OS environment or Vice Versa on Linux*</title>
      <description><![CDATA[ <p>The Intel C++ and Fortran Compiler for Linux* update 2 release contains the Japanese localized message catalog. After installing the Intel C++ and Fortran Compilers, you'll see the sub-folder:</p>
<ul>
<li>&lt;...&gt;/en_US for English message catalog or documentation</li>
<li>&lt;...&gt;/ja_JP for Japanese message catalog or documentation</li>
</ul>
<p><strong>Steps to see the Japanese message on an English development system</strong>: English OS</p>
<ol>
<li>Run following command: </li>
<p style="padding-left: 30px;">$ export LANG=ja_JP.UTF-8<br />or <br />$ export LC_ALL=ja_JP.UTF-8</p>
<li>Then all the compiler diagnostic message will be in Japanese.</li>
</ol>
<p><strong>Steps to see the English message on a Japanese development system</strong>: Japanese OS</p>
<ol>
<li>Run following command: </li>
<p style="padding-left: 30px;">$ export LANG=en_US.UTF-8<br />or <br />$ export LC_ALL=en_US.UTF-8</p>
<li>Then all the compiler diagnostic message will be in English.</li>
</ol>
<p> </p> ]]></description>
      <link>http://software.intel.com/en-us/articles/changing-language-setting-to-see-english-on-a-japanese-os-environment-or-vice-versa-on-linux</link>
      <pubDate>Mon, 14 Sep 2009 10:48:29 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/changing-language-setting-to-see-english-on-a-japanese-os-environment-or-vice-versa-on-linux#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/changing-language-setting-to-see-english-on-a-japanese-os-environment-or-vice-versa-on-linux</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
      <category>Intel® Fortran Compiler for Linux* Knowledge Base</category>
    </item>
    <item>
      <title>Using Intel Compilers for Linux with Caos Linux</title>
      <description><![CDATA[ Using Intel(R) Compilers under Caos NSA 1.0 Linux<br /><br />These notes apply to a Caos NSA 1.0 Linux Desktop installation.  Other installation types (server, base, etc) but should be similar but may require the installation of additional packages.<br /><br />In order to use Intel(R) Compilers ( Fortran or C++ ) under Caos Linux you will need the latest 11.1 version of the Intel compiler(s). Older 10.0 and 9.1 versions of the compilers may not work properly and have not been tested.  Keep in mind that Caos NSA Linux installations are not OFFICIALLY supported by the Intel Compilers.  Please see your ReleaseNotes document with your compiler version for a list of officially supported distributions and versions.<br /><br />If you have active support for your compiler, you can download the latest Intel compiler version from<br />https://registrationcenter.intel.com<br /><br />Follow the directions below after your network connection is configured.  Also, it is recommended that you first update your system to the latest version of Caos.  Open a terminal window as the root user.  Enter the following command to update your Caos installation:<br /><br />smart update<br />smart upgrade<br /><br />BEFORE YOU INSTALL Intel(R) Fortran for Linux or Intel(R) C++ for Linux on your fresh Caos NSA Desktop installation, you will first need to install several packages to prepare the system to serve as a development platform:<br /><br />Check that gcc and g++ are installed. By default. Check this with:<br /><br />gcc --version<br />g++ --version<br /><br />By default you may not have these packages installed.<br /><br />To prepare the system for the Intel Compilers, add the gcc-c++ and glibc-devel packages.  Open a terminal window as the root user.  Use 'smart' to install the following packages:<br /><br />smart install gcc-c++<br />smart install glibc-devel<br /><br />If you are in a 32bit, also known as "CAOS NSA 1.0 for i386" system, you may proceed with the installation of the Intel compilers (see below).  'uname -m' will return "i686" for this configuration.<br /><br /><b>For x86-64 architecture</b>, you will also need another package to supply 32bit libraries needed for developing 32bit applications in addition to 64bit applications.  First, determine the version of the 64bit version of glibc-devel that is installed:<br /><br />smart query glibc-devel<br /><br />the output should show both the 64bit and 32bit packages and their version.  For example:<br /><br />glibc-devel-2.8-13.nsa1@i686<br />glibc-devel-2.8-13.nsa1$x86_64<br /><br />Note that the versions you see may not match "2.8-13".  You may have a newer or older version available.  Find the 'i686' version and use smart install to fetch and install that package:<br /><br />smart install glibc-devel-2.8-13.nsa1@i686   <br /><br />for example.  Use the correct version returned by 'smart query' above, "2.8-13" is just an example to give you the idea.<br /><br /><br />Finally, there is an optional package to consider: The 11.0 version of the Intel Compiler for Linux has a graphical <br />debugger, a new graphical interface for the IDB debugger. If you want to use this debugger, please make sure to install the Java JRE version 1.5 or greater. This can be done at anytime after the installation of the compiler. However, you will get a warning message about 'missing prerequisite' for the JRE - simply ignore that message and proceed with the installation.  OR to avoid that message and enable the graphical IDE, get the latest JRE from:<br /><br /><a href="http://java.com/en/download/manual.jsp">http://java.com/en/download/manual.jsp</a><br /><br />Once installation of prerequisites is complete, you are ready to start the Intel compiler(s) installation. During the installation, you may get a message "Detected operating system (generic) is not supported", followed by<br />----------------------------------------------------------------- ---------------<br /> Missing optional pre-requisite<br /> -- operating system type is not supported.<br /> -- system glibc or kernel version not supported or not detectable<br /> -- binutils version not supported or not detectable<br /> ----------------------------------------------------------------- ---------------<br />"Would you like to perform an unsupported install of this product [yes/no] (no)?"<br /><br />enter "<b>yes</b>"<br /><br />This will complete the installation.  Keep in mind, <b>you will get this warning from the compiler installer until such time as this particular OS and version are supported.</b> Once installed, you can read the ReadMe notes in ...installdir.../Documentation directory which has a list of the supported Linux distributions and versions. ]]></description>
      <link>http://software.intel.com/en-us/articles/using-intel-compilers-for-linux-with-caos-linux</link>
      <pubDate>Fri, 28 Aug 2009 13:49:34 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/using-intel-compilers-for-linux-with-caos-linux#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/using-intel-compilers-for-linux-with-caos-linux</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
      <category>Intel® Fortran Compiler for Linux* Knowledge Base</category>
    </item>
    <item>
      <title>Memory allocation results in segmentation violation</title>
      <description><![CDATA[ <br />
<div id="art_pre_template"><b>Problem : <br /></b><br />I observe that when I compiled the following test case using default flag, its working properly. When I disabled optimization using flag -O0, it working for array size 10000, but unfortunately its giving segmentation fault error for size 100000.<br /><br />$ cat mytest1.c<br />// mytest1.c<br /><br />#include &lt;sys/time.h&gt;<br />#include &lt;time.h&gt;<br />#include&lt;stdio.h&gt;<br /><br />#define SIZE 1024 // Size = 1G<br />int main(int argc, char *argv[])<br />{<br />     float *a; //DB Init<br /><br />     long i,size=0,j;<br />     float sum=0;<br />     int k=0;<br />     int return_value;<br /><br /><br />     sscanf(argv[1], "%ld", &amp;size);<br />     printf("\n Size before Allocation = %ld\n",size);<br />     a=(float *) malloc (sizeof(float)* (size+128));<br /><br />     printf("Value of return from malloc = %d",return_value);<br /><br />     if (a == NULL){<br />         printf("\n\n ERROR: Memory Allocation not possible\n\n");<br />         exit(-1);<br />     }<br />     else<br />     {<br />         printf("Value of return pointer after memory allocation = %ld",a);<br />         printf("\n\n probing a[0]\n");<br />         a[0] = 0.;<br />         printf("probing a[%ld]\n", size-1);<br />         a[size-1] = 0.;<br />         printf("probing succeeded\n");<br />         return 0;<br />    }<br /><br />    for(i=0;i&lt; size; i++){<br />        sum+=a[i];<br />    }<br />    printf("\n Addition Complete, # of Element= %ld\n", size);<br />    free((void *)a);<br />    return 0;<br />}<br /><br /><br />$ icc -O0 mytest1.c <br />$ ./a.out 100000<br /><br />Size before Allocation = 100000<br />Value of return pointer after memory allocation = -1788305392<br /><br />probing a[0]<br />Segmentation fault<br /><br />$ icc mytest1.c <br />$ ./a.out 100000<br /><br />Size before Allocation = 100000<br />Value of return pointer after memory allocation = 182895288336<br /><br />probing a[0]<br />probing a[99999]<br />probing succeeded<br /><br /><br /><b>Environment : </b><br /><br />Intel C++ compiler, Linux x86_64<br /><br /><b>Root Cause : </b><br /><br />Implicitly declared malloc() returns improper address pointer and the application crashes. The compiler must know the function signature to handle it properly. <br /><br /><b>Resolution : </b><br /><br />Implicitly declared malloc() returns improper address pointer. The malloc() declaration in stdlib.h is as given below:<br /><br />void * malloc ( size_t size );<br /><br />The compiler must know the function signature to handle it properly. If we do not provide declaration to compiler, the compiler assumes that the value returned by the function is integer. This is called implicit declaration. <br /><br />The implicit declaration will force void pointer returned from malloc() to integer, the integer is converted again to float pointer. These conversions results in improper value for returned memory address and the application crashes.<br /><br /></div> ]]></description>
      <link>http://software.intel.com/en-us/articles/memory-allocation-results-in-segmentation-violation</link>
      <pubDate>Thu, 27 Aug 2009 23:40:59 -0700</pubDate>
      <comments>http://software.intel.com/en-us/articles/memory-allocation-results-in-segmentation-violation#comments</comments>
      <guid isPermaLink="true">http://software.intel.com/en-us/articles/memory-allocation-results-in-segmentation-violation</guid>
      <category>Intel® C++ Compiler for Linux* Knowledge Base</category>
      <category>Intel® C++ Compiler for Mac OS X* Knowledge Base</category>
    </item>
  </channel></rss>