This is an archive of the discontinued LLVM Phabricator instance.

Fix compilation error with -DLIBCXXABI_ENABLE_THREADS=OFF
ClosedPublic

Authored by michaelplatings on Apr 25 2019, 2:02 AM.

Details

Reviewers
EricWF
Summary

The error is:

libcxxabi/src/cxa_guard_impl.h: In instantiation of ‘__cxxabiv1::{anonymous}::LibcppMutex __cxxabiv1::{anonymous}::GlobalStatic<__cxxabiv1::{anonymous}::LibcppMutex>::instance’:
/work/llvm/llvm-project/libcxxabi/src/cxa_guard_impl.h:529:62:   required from here
/work/llvm/llvm-project/libcxxabi/src/cxa_guard_impl.h:510:23: error: ‘__cxxabiv1::{anonymous}::LibcppMutex __cxxabiv1::{anonymous}::GlobalStatic<__cxxabiv1::{anonymous}::LibcppMutex>::instance’ has incomplete type
 _LIBCPP_SAFE_STATIC T GlobalStatic<T>::instance = {};
                       ^

This was introduced in this commit: https://github.com/llvm/llvm-project/commit/70ebeabfb8330f805a26dbb2f8af77fb0ab0c5f0#diff-598857ff93b4283c6978bca09e013e02

Diff Detail

Event Timeline

Herald added a project: Restricted Project. · View Herald TranscriptApr 25 2019, 2:02 AM
michaelplatings edited the summary of this revision. (Show Details)Apr 25 2019, 2:03 AM
EricWF accepted this revision.Apr 25 2019, 2:09 AM

Thanks!

This revision is now accepted and ready to land.Apr 25 2019, 2:09 AM

@EricWF this change seems to have broken some a test somehow. I'm well out of my depth here so can you take a look?
http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast/builds/25356/steps/test/logs/stdio