Remove the is_mangled flag from Mangled and Symbol
authorAdrian Prantl <aprantl@apple.com>
Wed, 9 Oct 2019 16:22:14 +0000 (16:22 +0000)
committerAdrian Prantl <aprantl@apple.com>
Wed, 9 Oct 2019 16:22:14 +0000 (16:22 +0000)
commit939411c1aaa8830de2273849d5b8417788a25f67
tree4f2f34e5fd46e9e01298286eae4897b53656c501
parent6453f700f29a93ceb17ac43d6e8b802f9898fa6a
Remove the is_mangled flag from Mangled and Symbol

Testing whether a name is mangled or not is extremely cheap and can be
done by looking at the first two characters. Mangled knows how to do
it. On the flip side, many call sites that currently pass in an
is_mangled determination do not know how to correctly do it (for
example, they leave out Swift mangling prefixes).

This patch removes this entry point and just forced Mangled to
determine the mangledness of a string itself.

Differential Revision: https://reviews.llvm.org/D68674

llvm-svn: 374180
13 files changed:
lldb/include/lldb/Core/Mangled.h
lldb/include/lldb/Symbol/Function.h
lldb/include/lldb/Symbol/Symbol.h
lldb/source/API/SBType.cpp
lldb/source/Core/Mangled.cpp
lldb/source/Expression/IRExecutionUnit.cpp
lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp
lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
lldb/source/Plugins/SymbolFile/Breakpad/SymbolFileBreakpad.cpp
lldb/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp
lldb/source/Symbol/Function.cpp
lldb/source/Symbol/Symbol.cpp
lldb/unittests/Core/MangledTest.cpp