<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Hi Joachim,<div class=""><br class=""></div><div class=""><blockquote type="cite" class="">Any of the test targets are not available in the top-level build directory.<br class="">$ ninja check-libomp<br class="">ninja: error: unknown target 'check-libomp'<br class=""><br class="">Is anyone working on enabling this, if we really want to move towards<br class="">building OpenMP as runtime?</blockquote></div><div class=""><br class=""></div><div class="">This is because all targets in nested CMake run (the second CMake configure you saw to configure OpenMP) will not be exposed to the top level. Therefore, all OpenMP specific targets can not be used at the root build directory. However, you can use any of the following methods to invoke a test:</div><div class="">- <font face="Courier New" class="">ninja check-openmp</font></div><div class="">- Go to directory <font face="Courier New" class="">runtimes/runtimes-bins/openmp</font>, and do whatever you want like you’re in a standalone CMake project.</div><div class=""><br class=""></div><div class="">We’re not working on enabling it, and I’m not sure whether it is doable.</div><div class=""><br class=""></div><div class=""><blockquote type="cite" class="">The other issue when building OpenMP as a runtime is specific for the<br class="">tests check-libarcher:<br class=""><br class="">The tests depend on ThreadSanitizer support in the compiler. For the<br class="">in-tree build we currently check, whether the tsan target exists and<br class="">turn on the test in that case. When building OpenMP as a runtime, the<br class="">tsan target does not exist in that cmake environment. How should we pass<br class="">such and similar information down to the runtime build?</blockquote></div><div class=""><br class=""></div><div class="">We currently only use two packages for the second run: LLVM and Clang. If ThreadSanitizer is not part of the two packages, or it is not an external target, then it cannot be used. You can add the package you want in <font face="Courier New" class="">runtimes/CMakeLists.txt</font>.</div><div class=""><br class=""><div class="">
<div dir="auto" style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div>Regards,<br class="">Shilei<br class=""></div></div>
</div>
<div><br class=""><blockquote type="cite" class=""><div class="">On Feb 9, 2021, at 7:22 AM, Joachim Protze via Openmp-dev <<a href="mailto:openmp-dev@lists.llvm.org" class="">openmp-dev@lists.llvm.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">Hi all,<br class=""><br class="">after recent build issues when building OpenMP as a project<br class="">(LLVM_ENABLE_PROJECTS="...;openmp"), I started to build OpenMP as a<br class="">runtime (LLVM_ENABLE_RUNTIMES="...;openmp").<br class="">Currently I see two issues with this build setup:<br class=""><br class="">Any of the test targets are not available in the top-level build directory.<br class="">$ ninja check-libomp<br class="">ninja: error: unknown target 'check-libomp'<br class=""><br class="">Is anyone working on enabling this, if we really want to move towards<br class="">building OpenMP as runtime?<br class=""><br class=""><br class="">The other issue when building OpenMP as a runtime is specific for the<br class="">tests check-libarcher:<br class=""><br class="">The tests depend on ThreadSanitizer support in the compiler. For the<br class="">in-tree build we currently check, whether the tsan target exists and<br class="">turn on the test in that case. When building OpenMP as a runtime, the<br class="">tsan target does not exist in that cmake environment. How should we pass<br class="">such and similar information down to the runtime build?<br class=""><br class=""><br class="">Best<br class="">Joachim<br class=""><br class=""><br class="">_______________________________________________<br class="">Openmp-dev mailing list<br class=""><a href="mailto:Openmp-dev@lists.llvm.org" class="">Openmp-dev@lists.llvm.org</a><br class="">https://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev<br class=""></div></div></blockquote></div><br class=""></div></body></html>