This is an archive of the discontinued LLVM Phabricator instance.

[libc++abi] Optionally move __cxa_demangle into libc++demangle.a
Needs ReviewPublic

Authored by rprichard on Dec 6 2022, 5:54 PM.

Details

Reviewers
danalbert
Group Reviewers
Restricted Project
Summary

The motivation is to reduce the size of libc++.so on Android. The flag
is always used with LIBCXXABI_NON_DEMANGLING_TERMINATE.

Diff Detail

Event Timeline

rprichard created this revision.Dec 6 2022, 5:54 PM
Herald added a project: Restricted Project. · View Herald TranscriptDec 6 2022, 5:54 PM
rprichard requested review of this revision.Dec 6 2022, 5:54 PM
Herald added a project: Restricted Project. · View Herald TranscriptDec 6 2022, 5:54 PM
Herald added a reviewer: Restricted Project. · View Herald Transcript
rprichard retitled this revision from [libc++] Allow for omitting __cxa_demangle from libc++[abi].so to [libc++] Optionally move __cxa_demangle into libc++demangle.a.Dec 6 2022, 5:59 PM
rprichard edited the summary of this revision. (Show Details)
rprichard retitled this revision from [libc++] Optionally move __cxa_demangle into libc++demangle.a to [libc++abi] Optionally move __cxa_demangle into libc++demangle.a.
compnerd added inline comments.
libcxxabi/CMakeLists.txt
135

I think that we should at least emit a warning when this option is enabled. This makes libc++abi non-conforming as __cxa_demangle is part of the ABI definition as per https://itanium-cxx-abi.github.io/cxx-abi/abi.html.