<div dir="ltr">The following ALCF documentation may be relevant to folks who want to link ESSL (note the need for path modifications for installations with different filesystem organization).<div><br></div><div>Linking ESSL with GCC is a bit more complicated because the compiler runtime libraries will not be added automatically.</div><div><br></div><div>Please also note the LAPACK incompatibility issue. It might be fixed in later versions of ESSL on POWER, but as far as I know, it remains present on Blue Gene.<br><div><br></div><div>Jeff</div><div>(who wrote this documentation as an Argonne employee but now works for Intel and hasn't used Blue Gene much lately)<br><div><br></div><div>From <a href="https://wiki.alcf.anl.gov/parts/index.php/Blue_Gene/Q#Linking_ESSL">https://wiki.alcf.anl.gov/parts/index.php/Blue_Gene/Q#Linking_ESSL</a>:<br></div><div><br></div><div><h3 style="color:rgb(0,0,0);background-image:none;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;margin:0px 0px 0.3em;overflow:hidden;padding-top:0.5em;padding-bottom:0.17em;border-bottom:none;width:auto;font-size:16.764px;font-family:sans-serif"><span class="gmail-mw-headline" id="gmail-Linking_ESSL">Linking ESSL</span></h3><p style="margin:0.4em 0px 0.5em;line-height:1.5em;color:rgb(0,0,0);font-family:sans-serif;font-size:12.7px">ESSL does not provide full LAPACK so you need to link Netlib in first (from the left) if you rely upon proper LAPACK behavior. It is not just a missing-symbol issue but rather than one or more LAPACK symbols are implemented differently in ESSL in such a way as to break codes that assume Netlib LAPACK calling conventions.</p><h4 style="color:rgb(0,0,0);background-image:none;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;margin:0px 0px 0.3em;overflow:hidden;padding-top:0.5em;padding-bottom:0.17em;border-bottom:none;width:auto;font-size:14.732px;font-family:sans-serif"><span class="gmail-mw-headline" id="gmail-Single-threaded">Single-threaded</span></h4><p style="margin:0.4em 0px 0.5em;line-height:1.5em;color:rgb(0,0,0);font-family:sans-serif;font-size:12.7px">I avoid the use of <tt style="font-family:monospace,courier">-lxlomp_ser</tt> since I recall that it will break in some cases.</p><pre style="font-family:monospace,courier;padding:1em;border:1px dashed rgb(47,111,171);color:rgb(0,0,0);background-color:rgb(249,249,249);line-height:1.1em;font-size:12.7px">export IBMCMP_ROOT=${IBM_MAIN_DIR}
export BLAS_LIB=/soft/libraries/alcf/current/xl/BLAS/lib
export LAPACK_LIB=/soft/libraries/alcf/current/xl/LAPACK/lib
export ESSL_LIB=/soft/libraries/essl/current/essl/5.1/lib64
export XLF_LIB=${IBMCMP_ROOT}/xlf/bg/14.1/bglib64
export XLSMP_LIB=${IBMCMP_ROOT}/xlsmp/bg/3.1/bglib64
export XLMASS_LIB=${IBMCMP_ROOT}/xlmass/bg/7.3/bglib64
export MATH_LIBS="-L${XLMASS_LIB} -lmassv -lmass -L${LAPACK_LIB} -llapack \
-L${ESSL_LIB} -lesslbg -L${XLF_LIB} -lxlf90_r \
-L${XLSMP_LIB} -lxlsmp -lxlopt -lxlfmath -lxl \
-Wl,--allow-multiple-definition"
</pre><h4 style="color:rgb(0,0,0);background-image:none;background-position:initial;background-size:initial;background-repeat:initial;background-origin:initial;background-clip:initial;margin:0px 0px 0.3em;overflow:hidden;padding-top:0.5em;padding-bottom:0.17em;border-bottom:none;width:auto;font-size:14.732px;font-family:sans-serif"><span class="gmail-mw-headline" id="gmail-Multi-threaded">Multi-threaded</span></h4><p style="margin:0.4em 0px 0.5em;line-height:1.5em;color:rgb(0,0,0);font-family:sans-serif;font-size:12.7px">The key difference is is <tt style="font-family:monospace,courier">-lesslsmpbg</tt>.</p><pre style="font-family:monospace,courier;padding:1em;border:1px dashed rgb(47,111,171);color:rgb(0,0,0);background-color:rgb(249,249,249);line-height:1.1em;font-size:12.7px">export IBMCMP_ROOT=${IBM_MAIN_DIR}
export BLAS_LIB=/soft/libraries/alcf/current/xl/BLAS/lib
export LAPACK_LIB=/soft/libraries/alcf/current/xl/LAPACK/lib
export ESSL_LIB=/soft/libraries/essl/current/essl/5.1/lib64
export XLF_LIB=${IBMCMP_ROOT}/xlf/bg/14.1/bglib64
export XLSMP_LIB=${IBMCMP_ROOT}/xlsmp/bg/3.1/bglib64
export XLMASS_LIB=${IBMCMP_ROOT}/xlmass/bg/7.3/bglib64
export MATH_LIBS="-L${XLMASS_LIB} -lmassv -lmass -L${LAPACK_LIB} -llapack \
-L${ESSL_LIB} -lesslsmpbg -L${XLF_LIB} -lxlf90_r \
-L${XLSMP_LIB} -lxlsmp -lxlopt -lxlfmath -lxl \
-Wl,--allow-multiple-definition"</pre></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Feb 20, 2017 at 8:26 AM, Satish Balay <span dir="ltr"><<a href="mailto:balay@mcs.anl.gov" target="_blank">balay@mcs.anl.gov</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Mon, 20 Feb 2017, Barry Smith wrote:<br>
<br>
><br>
> > On Feb 20, 2017, at 5:13 AM, Pierre Jolivet <<a href="mailto:pierre.jolivet@enseeiht.fr">pierre.jolivet@enseeiht.fr</a>> wrote:<br>
> ><br>
> > Hello,<br>
> > It looks like the configure does not directly handle libesslsmpbg instead of libesslbg. On the other hand, it handles both libmkl_intel_thread and libmkl_sequential.<br>
> > Is there a reason for such a limitation? (I'd like to have direct solvers linked with threaded BLAS).<br>
><br>
> There is no reason. We wrote the essl interface many years ago and actually don't even have access to it any more. If you can make the additions and provide a pull request we'd be happy to include it.<br>
><br>
<br>
</span>The defaults are just that - defaults.<br>
<br>
One should use whatever blaslapack that suitable with the option --with-blas-lapack-lib option.<br>
<br>
Wrt libmkl_intel_thread vs libmkl_sequential - configure defaults to<br>
libmkl_sequential for reqular use.<br>
<br>
libmkl_intel_thread is picked up only when MKL pardiso is requested<br>
[so the assumption here is aware of pardiso requirements wrt<br>
threads].<br>
<br>
I see mkl check for windows is also looking for the thread version -<br>
don't remember the reason..<br>
<span class="HOEnZb"><font color="#888888"><br>
Satish<br>
<br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Jeff Hammond<br><a href="mailto:jeff.science@gmail.com" target="_blank">jeff.science@gmail.com</a><br><a href="http://jeffhammond.github.io/" target="_blank">http://jeffhammond.github.io/</a></div>
</div>