<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Nov 24, 2015 at 9:12 AM, Schlottke-Lakemper, Michael via cfe-users <span dir="ltr"><<a href="mailto:cfe-users@lists.llvm.org" target="_blank">cfe-users@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">



<div style="word-wrap:break-word">
Short update: I thought the behavior reported below it might be related to the fact that llvm-symbolizer picks up the “wrong” (i.e. the msan-implemented) version of libc++ once I put it in the LD_LIBRARY_PATH.</div></blockquote><div><br></div><div>Yes, I think that's what happening.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"> Thus I tried to compile a complete LLVM/Clang stack
 (with compiler-rt, libcxx, libcxxabi, libomp) using -DLLVM_USE_SANITIZER=MemoryWithOrigins. However, this did not work either, as apparently during the compilation process the memory sanitizer already comes to life and complains about use-of-unitialized values…
 Thus this approach seems to be a dead end.
<span class="HOEnZb"><font color="#888888"><div><br>
</div>
</font></span><div><span class="HOEnZb"><font color="#888888">Michael</font></span><div><div class="h5"><br>
<div>
<blockquote type="cite">
<div>On 24 Nov 2015, at 15:28 , Michael Schlottke-Lakemper <<a href="mailto:m.schlottke-lakemper@aia.rwth-aachen.de" target="_blank">m.schlottke-lakemper@aia.rwth-aachen.de</a>> wrote:</div>
<br>
<div>
<div style="word-wrap:break-word">
Hi folks,
<div><br>
</div>
<div>When running our msan-instrumented simulation program, instead of a proper output I get the following error:</div>
<div><br>
</div>
<div>==12089==WARNING: MemorySanitizer: use-of-uninitialized-value</div>
<div>
<div>==12089==WARNING: Can't read from symbolizer at fd 14</div>
<div>/pds/opt/llvm/bin/llvm-symbolizer: symbol lookup error: /pds/opt/libcxx-20151121-r253770-clang-msan/lib/libc++abi.so.1: undefined symbol: __msan_origin_tls</div>
<div>==12089==WARNING: external symbolizer didn't start up correctly!</div>
</div>
<div><br>
</div>
<div>My setup for using the memory sanitizer is as follows:</div>
<div>- compile libc++/libc++abi with -fsanitize=memory</div>
<div>- compile test program with normal (=uninstrumented) LLVM/Clang installation using -fsanitize=memory</div>
<div>- put instrumented libcxx/libcxxabi library dirs into LD_LIBRARY_PATH</div></div></div></blockquote></div></div></div></div></div></blockquote><div>Can you pass -Wl,-rpath when you link your executable, to specify the path to instrumented libc++/libc++abi?</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div><div><div class="h5"><div><blockquote type="cite"><div><div style="word-wrap:break-word">
<div>- run program</div>
<div><br>
</div>
<div>Any idea what I am doing wrong? Thanks a lot in advance!</div>
<div><br>
</div>
<div>Michael</div>
<br>
<br>
<br>
<div>
<div style="letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<span style="border-collapse:separate;font-family:Helvetica;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;border-spacing:0px">
<div style="word-wrap:break-word">
<span style="border-collapse:separate;font-family:Helvetica;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;border-spacing:0px">
<div style="word-wrap:break-word">
--<br>
Michael Schlottke-Lakemper<br>
<br>
Chair of Fluid Mechanics and Institute of Aerodynamics<br>
RWTH Aachen University<br>
Wüllnerstraße 5a<br>
52062 Aachen<br>
Germany<br>
<br>
Phone: <a href="tel:%2B49%20%28241%29%2080%2095188" value="+492418095188" target="_blank">+49 (241) 80 95188</a><br>
Fax: <a href="tel:%2B49%20%28241%29%2080%2092257" value="+492418092257" target="_blank">+49 (241) 80 92257</a><br>
Mail: <a href="mailto:m.schlottke-lakemper@aia.rwth-aachen.de" target="_blank">m.schlottke-lakemper@aia.rwth-aachen.de</a><br>
Web: <a href="http://www.aia.rwth-aachen.de/" target="_blank">http://www.aia.rwth-aachen.de</a></div>
</span></div>
</span></div>
</div>
<br>
</div>
</div>
</blockquote>
</div>
<br>
</div></div></div>
</div>

<br>_______________________________________________<br>
cfe-users mailing list<br>
<a href="mailto:cfe-users@lists.llvm.org">cfe-users@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr">Alexey Samsonov<br><a href="mailto:vonosmas@gmail.com" target="_blank">vonosmas@gmail.com</a></div></div>
</div></div>