<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Allow multiple copies of OpenMP runtime loaded in memory"
   href="https://bugs.llvm.org/show_bug.cgi?id=40664">40664</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Allow multiple copies of OpenMP runtime loaded in memory
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>OpenMP
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>unspecified
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Runtime Library
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>atilag@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>There seems to be a limitation in the OpenMP Runtime in which multiple copies
of the Runtime are not allowed for the same process [1].
This renders the usage of OpenMP through clang almost useless in some
situations where you don't have control over what other libraries are being
loaded into you process, like for example creating Python extensions (which are
loaded dynamically at runtime by common Python runtimes). C++ is being used
extensively here, and we cannot control what other libraries will be loaded so
there can exists situations where other extensions are using OpenMP so clashing
with your extension.
The thing is that this problem doesn't seem to exist using gcc libgomp
implementation, so I was wondering whether reviewing this limitation to get rid
of it worths the effort (as it sounds like a complex achievement). Python
extensions are a huge soure for clang users so I guess that it makes sense to
at least try to tackle this.

Thanks for your work!


[1]
<a href="https://github.com/llvm/llvm-project/blob/57b08b0944046a6a57ee9b7b479181f548a5b9b4/openmp/runtime/src/i18n/en_US.txt#L449">https://github.com/llvm/llvm-project/blob/57b08b0944046a6a57ee9b7b479181f548a5b9b4/openmp/runtime/src/i18n/en_US.txt#L449</a></pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>