[llvm] [Offload] Avoid global mutex destructors (PR #221471)

via llvm-commits llvm-commits at lists.llvm.org
Sat Sep 5 11:27:11 PDT 2026


github-actions[bot] wrote:

<!--PREMERGE ADVISOR COMMENT: Linux-->
# :penguin: Linux x64 Test Results

The build failed before running any tests. Click on a failure below to see the details.

<details>
<summary>offload/libomptarget/CMakeFiles/omptarget.dir/OffloadRTL.cpp.o</summary>

```
FAILED: offload/libomptarget/CMakeFiles/omptarget.dir/OffloadRTL.cpp.o
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/./bin/clang++ --target=x86_64-unknown-linux-gnu -DDEBUG_PREFIX=\"omptarget\" -DOMPT_SUPPORT=1 -DTARGET_NAME=omptarget -D_DEBUG -D_GLIBCXX_ASSERTIONS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Domptarget_EXPORTS -I/home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/build/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/build/runtimes/runtimes-bins/openmp/runtime/src -I/home/gha/actions-runner/_work/llvm-project/llvm-project/offload/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/build/runtimes/runtimes-bins/offload/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/offload/plugins-nextgen/common/include -I/home/gha/actions-runner/_work/llvm-project/llvm-project/build/runtimes/runtimes-bins/offload/plugins-nextgen/common/include -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion -Wno-pass-failed -Wmisleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -Xclang -fno-pch-timestamp -O3 -DNDEBUG -std=c++17 -fPIC -UNDEBUG -fno-exceptions -fno-rtti -Werror=global-constructors -MD -MT offload/libomptarget/CMakeFiles/omptarget.dir/OffloadRTL.cpp.o -MF offload/libomptarget/CMakeFiles/omptarget.dir/OffloadRTL.cpp.o.d -o offload/libomptarget/CMakeFiles/omptarget.dir/OffloadRTL.cpp.o -c /home/gha/actions-runner/_work/llvm-project/llvm-project/offload/libomptarget/OffloadRTL.cpp
/home/gha/actions-runner/_work/llvm-project/llvm-project/offload/libomptarget/OffloadRTL.cpp:42:3: error: 'std::scoped_lock' may not intend to support class template argument deduction [-Werror,-Wctad-maybe-unsupported]
42 |   std::scoped_lock Lock(getPluginMutex());
|   ^
/usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/mutex:740:11: note: add a deduction guide to suppress this warning
740 |     class scoped_lock
|           ^
/home/gha/actions-runner/_work/llvm-project/llvm-project/offload/libomptarget/OffloadRTL.cpp:68:3: error: 'std::scoped_lock' may not intend to support class template argument deduction [-Werror,-Wctad-maybe-unsupported]
68 |   std::scoped_lock Lock(getPluginMutex());
|   ^
/usr/lib/gcc/x86_64-linux-gnu/13/../../../../include/c++/13/mutex:740:11: note: add a deduction guide to suppress this warning
740 |     class scoped_lock
|           ^
2 errors generated.
```
</details>

If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.

https://github.com/llvm/llvm-project/pull/221471


More information about the llvm-commits mailing list