summaryrefslogtreecommitdiff
path: root/lldb/source/Plugins
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2015-08-24 23:46:31 +0000
committerGreg Clayton <gclayton@apple.com>2015-08-24 23:46:31 +0000
commita9de2ed3736bb7b7b08e1fe347210cb818b030c6 (patch)
treed33161e26e5568900f6a80e34355916199688e48 /lldb/source/Plugins
parent41f579f43dd0fcc0bec184c3f03104c231b5ed6f (diff)
Final bit of type system cleanup that abstracts declaration contexts into lldb_private::CompilerDeclContext and renames ClangType to CompilerType in many accessors and functions.
Create a new "lldb_private::CompilerDeclContext" class that will replace all direct uses of "clang::DeclContext" when used in compiler agnostic code, yet still allow for conversion to clang::DeclContext subclasses by clang specific code. This completes the abstraction of type parsing by removing all "clang::" references from the SymbolFileDWARF. The new "lldb_private::CompilerDeclContext" class abstracts decl contexts found in compiler type systems so they can be used in internal API calls. The TypeSystem is required to support CompilerDeclContexts with new pure virtual functions that start with "DeclContext" in the member function names. Converted all code that used lldb_private::ClangNamespaceDecl over to use the new CompilerDeclContext class and removed the ClangNamespaceDecl.cpp and ClangNamespaceDecl.h files. Removed direct use of clang APIs from SBType and now use the abstract type systems to correctly explore types. Bulk renames for things that used to return a ClangASTType which is now CompilerType: "Type::GetClangFullType()" to "Type::GetFullCompilerType()" "Type::GetClangLayoutType()" to "Type::GetLayoutCompilerType()" "Type::GetClangForwardType()" to "Type::GetForwardCompilerType()" "Value::GetClangType()" to "Value::GetCompilerType()" "Value::SetClangType (const CompilerType &)" to "Value::SetCompilerType (const CompilerType &)" "ValueObject::GetClangType ()" to "ValueObject::GetCompilerType()" many more renames that are similar.
Diffstat (limited to 'lldb/source/Plugins')
-rw-r--r--lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp6
-rw-r--r--lldb/source/Plugins/ABI/MacOSX-arm64/ABIMacOSX_arm64.cpp8
-rw-r--r--lldb/source/Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.cpp8
-rw-r--r--lldb/source/Plugins/ABI/SysV-arm/ABISysV_arm.cpp6
-rw-r--r--lldb/source/Plugins/ABI/SysV-arm64/ABISysV_arm64.cpp8
-rw-r--r--lldb/source/Plugins/ABI/SysV-i386/ABISysV_i386.cpp4
-rw-r--r--lldb/source/Plugins/ABI/SysV-mips/ABISysV_mips.cpp4
-rw-r--r--lldb/source/Plugins/ABI/SysV-mips64/ABISysV_mips64.cpp4
-rw-r--r--lldb/source/Plugins/ABI/SysV-ppc/ABISysV_ppc.cpp8
-rw-r--r--lldb/source/Plugins/ABI/SysV-ppc64/ABISysV_ppc64.cpp8
-rw-r--r--lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.cpp6
-rw-r--r--lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp4
-rw-r--r--lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp8
-rw-r--r--lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.cpp10
-rw-r--r--lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp14
-rw-r--r--lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.cpp6
-rw-r--r--lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp1
-rw-r--r--lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp1
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.h1
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp203
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h463
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp55
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h16
-rw-r--r--lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp63
-rw-r--r--lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.h23
-rw-r--r--lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetItemInfoHandler.cpp10
-rw-r--r--lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetPendingItemsHandler.cpp10
-rw-r--r--lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetQueuesHandler.cpp8
-rw-r--r--lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetThreadItemInfoHandler.cpp10
29 files changed, 519 insertions, 457 deletions
diff --git a/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp b/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
index 807e41cf87d..da2bab77b7f 100644
--- a/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
+++ b/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
@@ -333,7 +333,7 @@ ABIMacOSX_arm::GetArgumentValues (Thread &thread,
if (!value)
return false;
- CompilerType clang_type = value->GetClangType();
+ CompilerType clang_type = value->GetCompilerType();
if (clang_type)
{
bool is_signed = false;
@@ -430,7 +430,7 @@ ABIMacOSX_arm::GetReturnValueObjectImpl (Thread &thread,
return return_valobj_sp;
//value.SetContext (Value::eContextTypeClangType, clang_type.GetOpaqueQualType());
- value.SetClangType (clang_type);
+ value.SetCompilerType (clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
@@ -511,7 +511,7 @@ ABIMacOSX_arm::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueObj
return error;
}
- CompilerType clang_type = new_value_sp->GetClangType();
+ CompilerType clang_type = new_value_sp->GetCompilerType();
if (!clang_type)
{
error.SetErrorString ("Null clang type for return value.");
diff --git a/lldb/source/Plugins/ABI/MacOSX-arm64/ABIMacOSX_arm64.cpp b/lldb/source/Plugins/ABI/MacOSX-arm64/ABIMacOSX_arm64.cpp
index 407fa9cc2b5..4a4e6d1d437 100644
--- a/lldb/source/Plugins/ABI/MacOSX-arm64/ABIMacOSX_arm64.cpp
+++ b/lldb/source/Plugins/ABI/MacOSX-arm64/ABIMacOSX_arm64.cpp
@@ -322,7 +322,7 @@ ABIMacOSX_arm64::GetArgumentValues (Thread &thread, ValueList &values) const
if (!value)
return false;
- CompilerType value_type = value->GetClangType();
+ CompilerType value_type = value->GetCompilerType();
if (value_type)
{
bool is_signed = false;
@@ -424,7 +424,7 @@ ABIMacOSX_arm64::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueO
return error;
}
- CompilerType return_value_type = new_value_sp->GetClangType();
+ CompilerType return_value_type = new_value_sp->GetCompilerType();
if (!return_value_type)
{
error.SetErrorString ("Null clang type for return value.");
@@ -728,14 +728,12 @@ LoadValueFromConsecutiveGPRRegisters (ExecutionContext &exe_ctx,
const uint32_t homogeneous_count = value_type.IsHomogeneousAggregate (&base_type);
if (homogeneous_count > 0 && homogeneous_count <= 8)
{
- printf ("ClangASTContext::IsHomogeneousAggregate() => %u\n", homogeneous_count);
// Make sure we have enough registers
if (NSRN < 8 && (8-NSRN) >= homogeneous_count)
{
if (!base_type)
return false;
const size_t base_byte_size = base_type.GetByteSize(nullptr);
- printf ("ClangASTContext::IsHomogeneousAggregate() => base_byte_size = %" PRIu64 "\n", (uint64_t) base_byte_size);
uint32_t data_offset = 0;
for (uint32_t i=0; i<homogeneous_count; ++i)
@@ -871,7 +869,7 @@ ABIMacOSX_arm64::GetReturnValueObjectImpl (Thread &thread, CompilerType &return_
return return_valobj_sp;
//value.SetContext (Value::eContextTypeClangType, return_clang_type);
- value.SetClangType(return_clang_type);
+ value.SetCompilerType(return_clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.cpp b/lldb/source/Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.cpp
index 655d3c7dcdc..41a99772070 100644
--- a/lldb/source/Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.cpp
+++ b/lldb/source/Plugins/ABI/MacOSX-i386/ABIMacOSX_i386.cpp
@@ -418,7 +418,7 @@ ABIMacOSX_i386::PrepareNormalCall (Thread &thread,
break;
case Value::eValueTypeHostAddress:
{
- CompilerType clang_type (val->GetClangType());
+ CompilerType clang_type (val->GetCompilerType());
if (clang_type)
{
uint32_t cstr_length = 0;
@@ -545,7 +545,7 @@ ABIMacOSX_i386::GetArgumentValues (Thread &thread,
// We currently only support extracting values with Clang QualTypes.
// Do we care about others?
- CompilerType clang_type (value->GetClangType());
+ CompilerType clang_type (value->GetCompilerType());
if (clang_type)
{
bool is_signed;
@@ -582,7 +582,7 @@ ABIMacOSX_i386::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueOb
return error;
}
- CompilerType clang_type = new_value_sp->GetClangType();
+ CompilerType clang_type = new_value_sp->GetCompilerType();
if (!clang_type)
{
error.SetErrorString ("Null clang type for return value.");
@@ -663,7 +663,7 @@ ABIMacOSX_i386::GetReturnValueObjectImpl (Thread &thread,
return return_valobj_sp;
//value.SetContext (Value::eContextTypeClangType, clang_type.GetOpaqueQualType());
- value.SetClangType (clang_type);
+ value.SetCompilerType (clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/ABI/SysV-arm/ABISysV_arm.cpp b/lldb/source/Plugins/ABI/SysV-arm/ABISysV_arm.cpp
index d3536493dfc..a9b52a799b4 100644
--- a/lldb/source/Plugins/ABI/SysV-arm/ABISysV_arm.cpp
+++ b/lldb/source/Plugins/ABI/SysV-arm/ABISysV_arm.cpp
@@ -333,7 +333,7 @@ ABISysV_arm::GetArgumentValues (Thread &thread,
if (!value)
return false;
- CompilerType clang_type = value->GetClangType();
+ CompilerType clang_type = value->GetCompilerType();
if (clang_type)
{
bool is_signed = false;
@@ -426,7 +426,7 @@ ABISysV_arm::GetReturnValueObjectImpl (Thread &thread,
return return_valobj_sp;
//value.SetContext (Value::eContextTypeClangType, clang_type.GetOpaqueQualType());
- value.SetClangType (clang_type);
+ value.SetCompilerType (clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
@@ -579,7 +579,7 @@ ABISysV_arm::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueObjec
return error;
}
- CompilerType clang_type = new_value_sp->GetClangType();
+ CompilerType clang_type = new_value_sp->GetCompilerType();
if (!clang_type)
{
error.SetErrorString ("Null clang type for return value.");
diff --git a/lldb/source/Plugins/ABI/SysV-arm64/ABISysV_arm64.cpp b/lldb/source/Plugins/ABI/SysV-arm64/ABISysV_arm64.cpp
index e9b46983bf3..14b89ff3b5e 100644
--- a/lldb/source/Plugins/ABI/SysV-arm64/ABISysV_arm64.cpp
+++ b/lldb/source/Plugins/ABI/SysV-arm64/ABISysV_arm64.cpp
@@ -313,7 +313,7 @@ ABISysV_arm64::GetArgumentValues (Thread &thread, ValueList &values) const
if (!value)
return false;
- CompilerType value_type = value->GetClangType();
+ CompilerType value_type = value->GetCompilerType();
if (value_type)
{
bool is_signed = false;
@@ -397,7 +397,7 @@ ABISysV_arm64::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueObj
return error;
}
- CompilerType return_value_type = new_value_sp->GetClangType();
+ CompilerType return_value_type = new_value_sp->GetCompilerType();
if (!return_value_type)
{
error.SetErrorString ("Null clang type for return value.");
@@ -705,14 +705,12 @@ LoadValueFromConsecutiveGPRRegisters (ExecutionContext &exe_ctx,
const uint32_t homogeneous_count = value_type.IsHomogeneousAggregate (&base_type);
if (homogeneous_count > 0 && homogeneous_count <= 8)
{
- printf ("ClangASTContext::IsHomogeneousAggregate() => %u\n", homogeneous_count);
// Make sure we have enough registers
if (NSRN < 8 && (8-NSRN) >= homogeneous_count)
{
if (!base_type)
return false;
const size_t base_byte_size = base_type.GetByteSize(nullptr);
- printf ("ClangASTContext::IsHomogeneousAggregate() => base_byte_size = %" PRIu64 "\n", (uint64_t) base_byte_size);
uint32_t data_offset = 0;
for (uint32_t i=0; i<homogeneous_count; ++i)
@@ -841,7 +839,7 @@ ABISysV_arm64::GetReturnValueObjectImpl (Thread &thread, CompilerType &return_cl
return return_valobj_sp;
//value.SetContext (Value::eContextTypeClangType, return_clang_type);
- value.SetClangType(return_clang_type);
+ value.SetCompilerType(return_clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/ABI/SysV-i386/ABISysV_i386.cpp b/lldb/source/Plugins/ABI/SysV-i386/ABISysV_i386.cpp
index bce4f3c5e5d..c6f3fd2d32d 100644
--- a/lldb/source/Plugins/ABI/SysV-i386/ABISysV_i386.cpp
+++ b/lldb/source/Plugins/ABI/SysV-i386/ABISysV_i386.cpp
@@ -387,7 +387,7 @@ ABISysV_i386::GetArgumentValues (Thread &thread,
return false;
// Currently: Support for extracting values with Clang QualTypes only.
- CompilerType clang_type (value->GetClangType());
+ CompilerType clang_type (value->GetCompilerType());
if (clang_type)
{
bool is_signed;
@@ -434,7 +434,7 @@ ABISysV_i386::GetReturnValueObjectSimple (Thread &thread,
if (!return_clang_type)
return return_valobj_sp;
- value.SetClangType (return_clang_type);
+ value.SetCompilerType (return_clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/ABI/SysV-mips/ABISysV_mips.cpp b/lldb/source/Plugins/ABI/SysV-mips/ABISysV_mips.cpp
index d401ef3a3a5..2c897fc7bec 100644
--- a/lldb/source/Plugins/ABI/SysV-mips/ABISysV_mips.cpp
+++ b/lldb/source/Plugins/ABI/SysV-mips/ABISysV_mips.cpp
@@ -325,7 +325,7 @@ ABISysV_mips::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueObje
return error;
}
- CompilerType clang_type = new_value_sp->GetClangType();
+ CompilerType clang_type = new_value_sp->GetCompilerType();
if (!clang_type)
{
error.SetErrorString ("Null clang type for return value.");
@@ -417,7 +417,7 @@ ABISysV_mips::GetReturnValueObjectImpl (Thread &thread, CompilerType &return_cla
if (exe_ctx.GetTargetPtr() == NULL || exe_ctx.GetProcessPtr() == NULL)
return return_valobj_sp;
- value.SetClangType(return_clang_type);
+ value.SetCompilerType(return_clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/ABI/SysV-mips64/ABISysV_mips64.cpp b/lldb/source/Plugins/ABI/SysV-mips64/ABISysV_mips64.cpp
index 3d5b9d4f2cd..8b143f91438 100644
--- a/lldb/source/Plugins/ABI/SysV-mips64/ABISysV_mips64.cpp
+++ b/lldb/source/Plugins/ABI/SysV-mips64/ABISysV_mips64.cpp
@@ -290,7 +290,7 @@ ABISysV_mips64::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueOb
return error;
}
- CompilerType clang_type = new_value_sp->GetClangType();
+ CompilerType clang_type = new_value_sp->GetCompilerType();
if (!clang_type)
{
error.SetErrorString ("Null clang type for return value.");
@@ -385,7 +385,7 @@ ABISysV_mips64::GetReturnValueObjectImpl (Thread &thread, CompilerType &return_c
if (exe_ctx.GetTargetPtr() == NULL || exe_ctx.GetProcessPtr() == NULL)
return return_valobj_sp;
- value.SetClangType(return_clang_type);
+ value.SetCompilerType(return_clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/ABI/SysV-ppc/ABISysV_ppc.cpp b/lldb/source/Plugins/ABI/SysV-ppc/ABISysV_ppc.cpp
index f6f44646889..cc2fee24929 100644
--- a/lldb/source/Plugins/ABI/SysV-ppc/ABISysV_ppc.cpp
+++ b/lldb/source/Plugins/ABI/SysV-ppc/ABISysV_ppc.cpp
@@ -436,7 +436,7 @@ ABISysV_ppc::GetArgumentValues (Thread &thread,
// We currently only support extracting values with Clang QualTypes.
// Do we care about others?
- CompilerType clang_type = value->GetClangType();
+ CompilerType clang_type = value->GetCompilerType();
if (!clang_type)
return false;
bool is_signed;
@@ -476,7 +476,7 @@ ABISysV_ppc::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueObjec
return error;
}
- CompilerType clang_type = new_value_sp->GetClangType();
+ CompilerType clang_type = new_value_sp->GetCompilerType();
if (!clang_type)
{
error.SetErrorString ("Null clang type for return value.");
@@ -563,7 +563,7 @@ ABISysV_ppc::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueObjec
ValueObjectSP
ABISysV_ppc::GetReturnValueObjectSimple (Thread &thread,
- CompilerType &return_clang_type) const
+ CompilerType &return_clang_type) const
{
ValueObjectSP return_valobj_sp;
Value value;
@@ -572,7 +572,7 @@ ABISysV_ppc::GetReturnValueObjectSimple (Thread &thread,
return return_valobj_sp;
//value.SetContext (Value::eContextTypeClangType, return_value_type);
- value.SetClangType (return_clang_type);
+ value.SetCompilerType (return_clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/ABI/SysV-ppc64/ABISysV_ppc64.cpp b/lldb/source/Plugins/ABI/SysV-ppc64/ABISysV_ppc64.cpp
index f5402263d87..72fafe34e55 100644
--- a/lldb/source/Plugins/ABI/SysV-ppc64/ABISysV_ppc64.cpp
+++ b/lldb/source/Plugins/ABI/SysV-ppc64/ABISysV_ppc64.cpp
@@ -436,7 +436,7 @@ ABISysV_ppc64::GetArgumentValues (Thread &thread,
// We currently only support extracting values with Clang QualTypes.
// Do we care about others?
- CompilerType clang_type = value->GetClangType();
+ CompilerType clang_type = value->GetCompilerType();
if (!clang_type)
return false;
bool is_signed;
@@ -476,7 +476,7 @@ ABISysV_ppc64::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueObj
return error;
}
- CompilerType clang_type = new_value_sp->GetClangType();
+ CompilerType clang_type = new_value_sp->GetCompilerType();
if (!clang_type)
{
error.SetErrorString ("Null clang type for return value.");
@@ -563,7 +563,7 @@ ABISysV_ppc64::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueObj
ValueObjectSP
ABISysV_ppc64::GetReturnValueObjectSimple (Thread &thread,
- CompilerType &return_clang_type) const
+ CompilerType &return_clang_type) const
{
ValueObjectSP return_valobj_sp;
Value value;
@@ -572,7 +572,7 @@ ABISysV_ppc64::GetReturnValueObjectSimple (Thread &thread,
return return_valobj_sp;
//value.SetContext (Value::eContextTypeClangType, return_value_type);
- value.SetClangType (return_clang_type);
+ value.SetCompilerType (return_clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.cpp b/lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.cpp
index 25853f8d452..76cfdf15f33 100644
--- a/lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.cpp
+++ b/lldb/source/Plugins/ABI/SysV-x86_64/ABISysV_x86_64.cpp
@@ -502,7 +502,7 @@ ABISysV_x86_64::GetArgumentValues (Thread &thread,
// We currently only support extracting values with Clang QualTypes.
// Do we care about others?
- CompilerType clang_type = value->GetClangType();
+ CompilerType clang_type = value->GetCompilerType();
if (!clang_type)
return false;
bool is_signed;
@@ -542,7 +542,7 @@ ABISysV_x86_64::SetReturnValueObject(lldb::StackFrameSP &frame_sp, lldb::ValueOb
return error;
}
- CompilerType clang_type = new_value_sp->GetClangType();
+ CompilerType clang_type = new_value_sp->GetCompilerType();
if (!clang_type)
{
error.SetErrorString ("Null clang type for return value.");
@@ -642,7 +642,7 @@ ABISysV_x86_64::GetReturnValueObjectSimple (Thread &thread,
return return_valobj_sp;
//value.SetContext (Value::eContextTypeClangType, return_value_type);
- value.SetClangType (return_clang_type);
+ value.SetCompilerType (return_clang_type);
RegisterContext *reg_ctx = thread.GetRegisterContext().get();
if (!reg_ctx)
diff --git a/lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp b/lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp
index 31e1af55084..d5cc2a6fe8a 100644
--- a/lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp
+++ b/lldb/source/Plugins/DynamicLoader/MacOSX-DYLD/DynamicLoaderMacOSXDYLD.cpp
@@ -630,11 +630,11 @@ DynamicLoaderMacOSXDYLD::NotifyBreakpointHit (void *baton,
CompilerType clang_void_ptr_type = clang_ast_context->GetBasicType(eBasicTypeVoid).GetPointerType();
CompilerType clang_uint32_type = clang_ast_context->GetBuiltinTypeForEncodingAndBitSize(lldb::eEncodingUint, 32);
input_value.SetValueType (Value::eValueTypeScalar);
- input_value.SetClangType (clang_uint32_type);
+ input_value.SetCompilerType (clang_uint32_type);
// input_value.SetContext (Value::eContextTypeClangType, clang_uint32_type);
argument_values.PushValue (input_value);
argument_values.PushValue (input_value);
- input_value.SetClangType (clang_void_ptr_type);
+ input_value.SetCompilerType (clang_void_ptr_type);
// input_value.SetContext (Value::eContextTypeClangType, clang_void_ptr_type);
argument_values.PushValue (input_value);
diff --git a/lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp b/lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp
index 908a53c935f..375b9bb3894 100644
--- a/lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp
+++ b/lldb/source/Plugins/LanguageRuntime/CPlusPlus/ItaniumABI/ItaniumABILanguageRuntime.cpp
@@ -40,7 +40,7 @@ ItaniumABILanguageRuntime::CouldHaveDynamicValue (ValueObject &in_value)
{
const bool check_cxx = true;
const bool check_objc = false;
- return in_value.GetClangType().IsPossibleDynamicType (NULL, check_cxx, check_objc);
+ return in_value.GetCompilerType().IsPossibleDynamicType (NULL, check_cxx, check_objc);
}
bool
@@ -189,7 +189,7 @@ ItaniumABILanguageRuntime::GetDynamicTypeAndAddress (ValueObject &in_value,
type_sp = class_types.GetTypeAtIndex(i);
if (type_sp)
{
- if (ClangASTContext::IsCXXClassType(type_sp->GetClangFullType()))
+ if (ClangASTContext::IsCXXClassType(type_sp->GetFullCompilerType ()))
{
if (log)
log->Printf ("0x%16.16" PRIx64 ": static-type = '%s' has multiple matching dynamic types, picking this one: uid={0x%" PRIx64 "}, type-name='%s'\n",
@@ -221,8 +221,8 @@ ItaniumABILanguageRuntime::GetDynamicTypeAndAddress (ValueObject &in_value,
// the value we were handed.
if (type_sp)
{
- if (ClangASTContext::AreTypesSame (in_value.GetClangType(),
- type_sp->GetClangFullType()))
+ if (ClangASTContext::AreTypesSame (in_value.GetCompilerType(),
+ type_sp->GetFullCompilerType ()))
{
// The dynamic type we found was the same type,
// so we don't have a dynamic type here...
diff --git a/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.cpp b/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.cpp
index f05f885d4f0..81ae61841ae 100644
--- a/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.cpp
+++ b/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntime.cpp
@@ -51,7 +51,7 @@ AppleObjCRuntime::AppleObjCRuntime(Process *process) :
bool
AppleObjCRuntime::GetObjectDescription (Stream &str, ValueObject &valobj)
{
- CompilerType clang_type(valobj.GetClangType());
+ CompilerType clang_type(valobj.GetCompilerType());
bool is_signed;
// ObjC objects can only be pointers (or numbers that actually represents pointers
// but haven't been typecast, because reasons..)
@@ -89,7 +89,7 @@ AppleObjCRuntime::GetObjectDescription (Stream &strm, Value &value, ExecutionCon
return false;
Target *target = exe_ctx.GetTargetPtr();
- CompilerType clang_type = value.GetClangType();
+ CompilerType clang_type = value.GetCompilerType();
if (clang_type)
{
if (!ClangASTContext::IsObjCObjectPointerType(clang_type))
@@ -106,7 +106,7 @@ AppleObjCRuntime::GetObjectDescription (Stream &strm, Value &value, ExecutionCon
if (!opaque_type)
opaque_type = ast_context->GetBasicType(eBasicTypeVoid).GetPointerType();
//value.SetContext(Value::eContextTypeClangType, opaque_type_ptr);
- value.SetClangType (opaque_type);
+ value.SetCompilerType (opaque_type);
}
ValueList arg_value_list;
@@ -118,7 +118,7 @@ AppleObjCRuntime::GetObjectDescription (Stream &strm, Value &value, ExecutionCon
CompilerType return_clang_type = ast_context->GetCStringType(true);
Value ret;
// ret.SetContext(Value::eContextTypeClangType, return_clang_type);
- ret.SetClangType (return_clang_type);
+ ret.SetCompilerType (return_clang_type);
if (exe_ctx.GetFramePtr() == NULL)
{
@@ -229,7 +229,7 @@ AppleObjCRuntime::GetPrintForDebuggerAddr()
bool
AppleObjCRuntime::CouldHaveDynamicValue (ValueObject &in_value)
{
- return in_value.GetClangType().IsPossibleDynamicType (NULL,
+ return in_value.GetCompilerType().IsPossibleDynamicType (NULL,
false, // do not check C++
true); // check ObjC
}
diff --git a/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp b/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp
index 5d4ba3acacd..4817d57a353 100644
--- a/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp
+++ b/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCRuntimeV2.cpp
@@ -1139,7 +1139,7 @@ AppleObjCRuntimeV2::GetClassDescriptor (ValueObject& valobj)
// if we get an invalid VO (which might still happen when playing around
// with pointers returned by the expression parser, don't consider this
// a valid ObjC object)
- if (valobj.GetClangType().IsValid())
+ if (valobj.GetCompilerType().IsValid())
{
addr_t isa_pointer = valobj.GetPointerValue();
@@ -1276,13 +1276,13 @@ AppleObjCRuntimeV2::UpdateISAToDescriptorMapDynamic(RemoteNXMapTable &hash_table
Value value;
value.SetValueType (Value::eValueTypeScalar);
// value.SetContext (Value::eContextTypeClangType, clang_void_pointer_type);
- value.SetClangType (clang_void_pointer_type);
+ value.SetCompilerType (clang_void_pointer_type);
arguments.PushValue (value);
arguments.PushValue (value);
value.SetValueType (Value::eValueTypeScalar);
// value.SetContext (Value::eContextTypeClangType, clang_uint32_t_type);
- value.SetClangType (clang_uint32_t_type);
+ value.SetCompilerType (clang_uint32_t_type);
arguments.PushValue (value);
m_get_class_info_function.reset(new ClangFunction (*m_process,
@@ -1355,7 +1355,7 @@ AppleObjCRuntimeV2::UpdateISAToDescriptorMapDynamic(RemoteNXMapTable &hash_table
Value return_value;
return_value.SetValueType (Value::eValueTypeScalar);
//return_value.SetContext (Value::eContextTypeClangType, clang_uint32_t_type);
- return_value.SetClangType (clang_uint32_t_type);
+ return_value.SetCompilerType (clang_uint32_t_type);
return_value.GetScalar() = 0;
errors.Clear();
@@ -1530,13 +1530,13 @@ AppleObjCRuntimeV2::UpdateISAToDescriptorMapSharedCache()
Value value;
value.SetValueType (Value::eValueTypeScalar);
//value.SetContext (Value::eContextTypeClangType, clang_void_pointer_type);
- value.SetClangType (clang_void_pointer_type);
+ value.SetCompilerType (clang_void_pointer_type);
arguments.PushValue (value);
arguments.PushValue (value);
value.SetValueType (Value::eValueTypeScalar);
//value.SetContext (Value::eContextTypeClangType, clang_uint32_t_type);
- value.SetClangType (clang_uint32_t_type);
+ value.SetCompilerType (clang_uint32_t_type);
arguments.PushValue (value);
m_get_shared_cache_class_info_function.reset(new ClangFunction (*m_process,
@@ -1610,7 +1610,7 @@ AppleObjCRuntimeV2::UpdateISAToDescriptorMapSharedCache()
Value return_value;
return_value.SetValueType (Value::eValueTypeScalar);
//return_value.SetContext (Value::eContextTypeClangType, clang_uint32_t_type);
- return_value.SetClangType (clang_uint32_t_type);
+ return_value.SetCompilerType (clang_uint32_t_type);
return_value.GetScalar() = 0;
errors.Clear();
diff --git a/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.cpp b/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.cpp
index 40f8e89a57b..3e5bb8c749a 100644
--- a/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.cpp
+++ b/lldb/source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleObjCTrampolineHandler.cpp
@@ -526,7 +526,7 @@ AppleObjCTrampolineHandler::AppleObjCVTables::RefreshTrampolines (void *baton,
input_value.SetValueType (Value::eValueTypeScalar);
//input_value.SetContext (Value::eContextTypeClangType, clang_void_ptr_type);
- input_value.SetClangType (clang_void_ptr_type);
+ input_value.SetCompilerType (clang_void_ptr_type);
argument_values.PushValue(input_value);
bool success = abi->GetArgumentValues (exe_ctx.GetThreadRef(), argument_values);
@@ -901,7 +901,7 @@ AppleObjCTrampolineHandler::GetStepThroughDispatchPlan (Thread &thread, bool sto
CompilerType clang_void_ptr_type = clang_ast_context->GetBasicType(eBasicTypeVoid).GetPointerType();
void_ptr_value.SetValueType (Value::eValueTypeScalar);
//void_ptr_value.SetContext (Value::eContextTypeClangType, clang_void_ptr_type);
- void_ptr_value.SetClangType (clang_void_ptr_type);
+ void_ptr_value.SetCompilerType (clang_void_ptr_type);
int obj_index;
int sel_index;
@@ -1083,7 +1083,7 @@ AppleObjCTrampolineHandler::GetStepThroughDispatchPlan (Thread &thread, bool sto
CompilerType clang_int_type = clang_ast_context->GetBuiltinTypeForEncodingAndBitSize(lldb::eEncodingSint, 32);
flag_value.SetValueType (Value::eValueTypeScalar);
//flag_value.SetContext (Value::eContextTypeClangType, clang_int_type);
- flag_value.SetClangType (clang_int_type);
+ flag_value.SetCompilerType (clang_int_type);
if (this_dispatch.stret_return)
flag_value.GetScalar() = 1;
diff --git a/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp b/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
index 329db1c5949..e95a31c4845 100644
--- a/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
+++ b/lldb/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
@@ -26,7 +26,6 @@
#include "lldb/Core/UUID.h"
#include "lldb/Host/Host.h"
#include "lldb/Host/FileSpec.h"
-#include "lldb/Symbol/ClangNamespaceDecl.h"
#include "lldb/Symbol/DWARFCallFrameInfo.h"
#include "lldb/Symbol/ObjectFile.h"
#include "lldb/Target/MemoryRegionInfo.h"
diff --git a/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp b/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp
index e744d13deec..93a52d1206e 100644
--- a/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp
+++ b/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp
@@ -24,7 +24,6 @@
#include "lldb/Core/ValueObjectVariable.h"
#include "lldb/Interpreter/CommandInterpreter.h"
#include "lldb/Interpreter/ScriptInterpreter.h"
-#include "lldb/Symbol/ClangNamespaceDecl.h"
#include "lldb/Symbol/ObjectFile.h"
#include "lldb/Symbol/VariableList.h"
#include "lldb/Target/Process.h"
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.h b/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.h
index 3949ad339dd..d8af6342660 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.h
+++ b/lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.h
@@ -85,7 +85,6 @@ public:
dw_attr_t attr;
dw_form_t form;
};
-
typedef llvm::SmallVector<Info, 8> collection;
collection m_infos;
};
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
index 35095fcfccd..c8ca9f99da3 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
@@ -461,7 +461,7 @@ SymbolFileDWARF::GetTypes (SymbolContextScope *sc_scope,
size_t num_types_added = 0;
for (Type *type : type_set)
{
- CompilerType clang_type = type->GetClangForwardType();
+ CompilerType clang_type = type->GetForwardCompilerType ();
if (clang_type_set.find(clang_type) == clang_type_set.end())
{
clang_type_set.insert(clang_type);
@@ -1432,8 +1432,8 @@ SymbolFileDWARF::ClassOrStructIsVirtual (DWARFCompileUnit* dwarf_cu,
return false;
}
-clang::DeclContext*
-SymbolFileDWARF::GetClangDeclContextContainingTypeUID (lldb::user_id_t type_uid)
+CompilerDeclContext
+SymbolFileDWARF::GetDeclContextForUID (lldb::user_id_t type_uid)
{
if (UserIDMatches(type_uid))
{
@@ -1446,15 +1446,15 @@ SymbolFileDWARF::GetClangDeclContextContainingTypeUID (lldb::user_id_t type_uid)
{
TypeSystem *type_system = GetTypeSystemForLanguage(cu_sp->GetLanguageType());
if (type_system)
- return type_system->GetClangDeclContextContainingTypeUID(this, type_uid);
+ return type_system->GetDeclContextForUIDFromDWARF(this, cu_sp.get(), die);
}
}
}
- return NULL;
+ return CompilerDeclContext();
}
-clang::DeclContext*
-SymbolFileDWARF::GetClangDeclContextForTypeUID (const lldb_private::SymbolContext &sc, lldb::user_id_t type_uid)
+CompilerDeclContext
+SymbolFileDWARF::GetDeclContextContainingUID (lldb::user_id_t type_uid)
{
if (UserIDMatches(type_uid))
{
@@ -1467,13 +1467,14 @@ SymbolFileDWARF::GetClangDeclContextForTypeUID (const lldb_private::SymbolContex
{
TypeSystem *type_system = GetTypeSystemForLanguage(cu_sp->GetLanguageType());
if (type_system)
- return type_system->GetClangDeclContextForTypeUID(this, sc, type_uid);
+ return type_system->GetDeclContextContainingUIDFromDWARF(this, cu_sp.get(), die);
}
}
}
- return NULL;
+ return CompilerDeclContext();
}
+
Type*
SymbolFileDWARF::ResolveTypeUID (lldb::user_id_t type_uid)
{
@@ -1537,7 +1538,7 @@ SymbolFileDWARF::ResolveTypeUID (DWARFCompileUnit* cu, const DWARFDebugInfoEntry
// // want a function (method or static) from a class, the class must
// // create itself and add it's own methods and class functions.
// if (parent_type)
-// parent_type->GetClangFullType();
+// parent_type->GetFullCompilerType ();
// }
}
break;
@@ -2134,24 +2135,18 @@ SymbolFileDWARF::Index ()
}
bool
-SymbolFileDWARF::NamespaceDeclMatchesThisSymbolFile (const ClangNamespaceDecl *namespace_decl)
+SymbolFileDWARF::DeclContextMatchesThisSymbolFile (const lldb_private::CompilerDeclContext *decl_ctx)
{
- if (namespace_decl == NULL)
+ if (decl_ctx == nullptr || !decl_ctx->IsValid())
{
// Invalid namespace decl which means we aren't matching only things
// in this symbol file, so return true to indicate it matches this
// symbol file.
return true;
}
-
- clang::ASTContext *namespace_ast = namespace_decl->GetASTContext();
-
- if (namespace_ast == NULL)
- return true; // No AST in the "namespace_decl", return true since it
- // could then match any symbol file, including this one
- if (namespace_ast == GetClangASTContext().getASTContext())
- return true; // The ASTs match, return true
+ if ((TypeSystem *)&GetClangASTContext() == decl_ctx->GetTypeSystem())
+ return true; // The type systems match, return true
// The namespace AST was valid, and it does not match...
Log *log (LogChannelDWARF::GetLogIfAll(DWARF_LOG_LOOKUPS));
@@ -2163,18 +2158,18 @@ SymbolFileDWARF::NamespaceDeclMatchesThisSymbolFile (const ClangNamespaceDecl *n
}
uint32_t
-SymbolFileDWARF::FindGlobalVariables (const ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, VariableList& variables)
+SymbolFileDWARF::FindGlobalVariables (const ConstString &name, const CompilerDeclContext *parent_decl_ctx, bool append, uint32_t max_matches, VariableList& variables)
{
Log *log (LogChannelDWARF::GetLogIfAll(DWARF_LOG_LOOKUPS));
if (log)
GetObjectFile()->GetModule()->LogMessage (log,
- "SymbolFileDWARF::FindGlobalVariables (name=\"%s\", namespace_decl=%p, append=%u, max_matches=%u, variables)",
+ "SymbolFileDWARF::FindGlobalVariables (name=\"%s\", parent_decl_ctx=%p, append=%u, max_matches=%u, variables)",
name.GetCString(),
- static_cast<const void*>(namespace_decl),
+ static_cast<const void*>(parent_decl_ctx),
append, max_matches);
- if (!NamespaceDeclMatchesThisSymbolFile(namespace_decl))
+ if (!DeclContextMatchesThisSymbolFile(parent_decl_ctx))
return 0;
DWARFDebugInfo* info = DebugInfo();
@@ -2245,12 +2240,16 @@ SymbolFileDWARF::FindGlobalVariables (const ConstString &name, const lldb_privat
{
sc.comp_unit = GetCompUnitForDWARFCompUnit(dwarf_cu, UINT32_MAX);
- if (namespace_decl)
+ if (parent_decl_ctx)
{
TypeSystem *type_system = GetTypeSystemForLanguage(dwarf_cu->GetLanguageType());
- if (!type_system->DIEIsInNamespace (namespace_decl, this, dwarf_cu, die))
- continue;
+ if (type_system)
+ {
+ CompilerDeclContext actual_parent_decl_ctx = type_system->GetDeclContextContainingUIDFromDWARF (this, dwarf_cu, die);
+ if (!actual_parent_decl_ctx || actual_parent_decl_ctx != *parent_decl_ctx)
+ continue;
+ }
}
ParseVariables(sc, dwarf_cu, LLDB_INVALID_ADDRESS, die, false, false, &variables);
@@ -2277,9 +2276,9 @@ SymbolFileDWARF::FindGlobalVariables (const ConstString &name, const lldb_privat
if (log && num_matches > 0)
{
GetObjectFile()->GetModule()->LogMessage (log,
- "SymbolFileDWARF::FindGlobalVariables (name=\"%s\", namespace_decl=%p, append=%u, max_matches=%u, variables) => %u",
+ "SymbolFileDWARF::FindGlobalVariables (name=\"%s\", parent_decl_ctx=%p, append=%u, max_matches=%u, variables) => %u",
name.GetCString(),
- static_cast<const void*>(namespace_decl),
+ static_cast<const void*>(parent_decl_ctx),
append, max_matches,
num_matches);
}
@@ -2614,9 +2613,34 @@ SymbolFileDWARF::FunctionDieMatchesPartialName (const DWARFDebugInfoEntry* die,
return true;
}
+bool
+SymbolFileDWARF::DIEInDeclContext (const CompilerDeclContext *decl_ctx,
+ DWARFCompileUnit *cu,
+ const DWARFDebugInfoEntry *die)
+{
+ // If we have no parent decl context to match this DIE matches, and if the parent
+ // decl context isn't valid, we aren't trying to look for any particular decl
+ // context so any die matches.
+ if (decl_ctx == nullptr || !decl_ctx->IsValid())
+ return true;
+
+ if (cu && die)
+ {
+ TypeSystem *type_system = GetTypeSystemForLanguage(cu->GetLanguageType());
+
+ if (type_system)
+ {
+ CompilerDeclContext actual_decl_ctx = type_system->GetDeclContextContainingUIDFromDWARF (this, cu, die);
+ if (actual_decl_ctx)
+ return actual_decl_ctx == *decl_ctx;
+ }
+ }
+ return false;
+}
+
uint32_t
-SymbolFileDWARF::FindFunctions (const ConstString &name,
- const lldb_private::ClangNamespaceDecl *namespace_decl,
+SymbolFileDWARF::FindFunctions (const ConstString &name,
+ const CompilerDeclContext *parent_decl_ctx,
uint32_t name_type_mask,
bool include_inlines,
bool append,
@@ -2644,7 +2668,7 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
if (!append)
sc_list.Clear();
- if (!NamespaceDeclMatchesThisSymbolFile(namespace_decl))
+ if (!DeclContextMatchesThisSymbolFile(parent_decl_ctx))
return 0;
// If name is empty then we won't find anything.
@@ -2685,13 +2709,8 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
const DWARFDebugInfoEntry *die = info->GetDIEPtrWithCompileUnitHint (die_offset, &dwarf_cu);
if (die)
{
- if (namespace_decl)
- {
- TypeSystem *type_system = GetTypeSystemForLanguage(dwarf_cu->GetLanguageType());
-
- if (!type_system->DIEIsInNamespace (namespace_decl, this, dwarf_cu, die))
- continue;
- }
+ if (!DIEInDeclContext(parent_decl_ctx, dwarf_cu, die))
+ continue; // The containing decl contexts don't match
if (resolved_dies.find(die) == resolved_dies.end())
{
@@ -2709,7 +2728,7 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
if (name_type_mask & eFunctionNameTypeSelector)
{
- if (namespace_decl && *namespace_decl)
+ if (parent_decl_ctx && parent_decl_ctx->IsValid())
return 0; // no selectors in namespaces
num_matches = m_apple_names_ap->FindByName (name_cstr, die_offsets);
@@ -2741,7 +2760,7 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
die_offsets.clear();
}
- if (((name_type_mask & eFunctionNameTypeMethod) && !namespace_decl) || name_type_mask & eFunctionNameTypeBase)
+ if (((name_type_mask & eFunctionNameTypeMethod) && !parent_decl_ctx) || name_type_mask & eFunctionNameTypeBase)
{
// The apple_names table stores just the "base name" of C++ methods in the table. So we have to
// extract the base name, look that up, and if there is any other information in the name we were
@@ -2756,13 +2775,9 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
const DWARFDebugInfoEntry* die = info->GetDIEPtrWithCompileUnitHint (die_offset, &dwarf_cu);
if (die)
{
- if (namespace_decl)
- {
- TypeSystem *type_system = GetTypeSystemForLanguage(dwarf_cu->GetLanguageType());
+ if (!DIEInDeclContext(parent_decl_ctx, dwarf_cu, die))
+ continue; // The containing decl contexts don't match
- if (!type_system->DIEIsInNamespace (namespace_decl, this, dwarf_cu, die))
- continue;
- }
// If we get to here, the die is good, and we should add it:
if (resolved_dies.find(die) == resolved_dies.end())
@@ -2786,8 +2801,8 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
if (type)
{
- clang::DeclContext* decl_ctx = GetClangDeclContextContainingTypeUID (type->GetID());
- if (decl_ctx->isRecord())
+ CompilerDeclContext decl_ctx = GetDeclContextContainingUID (type->GetID());
+ if (decl_ctx.IsStructUnionOrClass())
{
if (name_type_mask & eFunctionNameTypeBase)
{
@@ -2849,7 +2864,7 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
if (sc_list.GetSize() == 0)
{
ArchSpec arch;
- if (!namespace_decl &&
+ if (!parent_decl_ctx &&
GetObjectFile()->GetArchitecture(arch) &&
(arch.GetTriple().isOSFreeBSD() || arch.GetTriple().isOSLinux() ||
arch.GetMachine() == llvm::Triple::hexagon))
@@ -2886,13 +2901,8 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
const DWARFDebugInfoEntry* die = info->GetDIEPtrWithCompileUnitHint (die_offsets[i], &dwarf_cu);
if (die)
{
- if (namespace_decl)
- {
- TypeSystem *type_system = GetTypeSystemForLanguage(dwarf_cu->GetLanguageType());
-
- if (!type_system->DIEIsInNamespace (namespace_decl, this, dwarf_cu, die))
- continue;
- }
+ if (!DIEInDeclContext(parent_decl_ctx, dwarf_cu, die))
+ continue; // The containing decl contexts don't match
// If we get to here, the die is good, and we should add it:
if (resolved_dies.find(die) == resolved_dies.end())
@@ -2907,7 +2917,7 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
if (name_type_mask & eFunctionNameTypeMethod)
{
- if (namespace_decl && *namespace_decl)
+ if (parent_decl_ctx && parent_decl_ctx->IsValid())
return 0; // no methods in namespaces
uint32_t num_base = m_function_method_index.Find(name, die_offsets);
@@ -2929,7 +2939,7 @@ SymbolFileDWARF::FindFunctions (const ConstString &name,
die_offsets.clear();
}
- if ((name_type_mask & eFunctionNameTypeSelector) && (!namespace_decl || !*namespace_decl))
+ if ((name_type_mask & eFunctionNameTypeSelector) && (!parent_decl_ctx || !parent_decl_ctx->IsValid()))
{
FindFunctions (name, m_function_selector_index, include_inlines, sc_list);
}
@@ -3001,7 +3011,7 @@ SymbolFileDWARF::FindFunctions(const RegularExpression& regex, bool include_inli
uint32_t
SymbolFileDWARF::FindTypes (const SymbolContext& sc,
const ConstString &name,
- const lldb_private::ClangNamespaceDecl *namespace_decl,
+ const CompilerDeclContext *parent_decl_ctx,
bool append,
uint32_t max_matches,
TypeList& types)
@@ -3014,16 +3024,16 @@ SymbolFileDWARF::FindTypes (const SymbolContext& sc,
if (log)
{
- if (namespace_decl)
+ if (parent_decl_ctx)
GetObjectFile()->GetModule()->LogMessage (log,
- "SymbolFileDWARF::FindTypes (sc, name=\"%s\", clang::NamespaceDecl(%p) \"%s\", append=%u, max_matches=%u, type_list)",
+ "SymbolFileDWARF::FindTypes (sc, name=\"%s\", parent_decl_ctx = %p (\"%s\"), append=%u, max_matches=%u, type_list)",
name.GetCString(),
- static_cast<void*>(namespace_decl->GetNamespaceDecl()),
- namespace_decl->GetQualifiedName().c_str(),
+ static_cast<const void*>(parent_decl_ctx),
+ parent_decl_ctx->GetName().AsCString("<NULL>"),
append, max_matches);
else
GetObjectFile()->GetModule()->LogMessage (log,
- "SymbolFileDWARF::FindTypes (sc, name=\"%s\", clang::NamespaceDecl(NULL), append=%u, max_matches=%u, type_list)",
+ "SymbolFileDWARF::FindTypes (sc, name=\"%s\", parent_decl_ctx = NULL, append=%u, max_matches=%u, type_list)",
name.GetCString(), append,
max_matches);
}
@@ -3032,7 +3042,7 @@ SymbolFileDWARF::FindTypes (const SymbolContext& sc,
if (!append)
types.Clear();
- if (!NamespaceDeclMatchesThisSymbolFile(namespace_decl))
+ if (!DeclContextMatchesThisSymbolFile(parent_decl_ctx))
return 0;
DIEArray die_offsets;
@@ -3068,13 +3078,8 @@ SymbolFileDWARF::FindTypes (const SymbolContext& sc,
if (die)
{
- if (namespace_decl)
- {
- TypeSystem *type_system = GetTypeSystemForLanguage(dwarf_cu->GetLanguageType());
-
- if (!type_system->DIEIsInNamespace (namespace_decl, this, dwarf_cu, die))
- continue;
- }
+ if (!DIEInDeclContext(parent_decl_ctx, dwarf_cu, die))
+ continue; // The containing decl contexts don't match
Type *matching_type = ResolveType (dwarf_cu, die);
if (matching_type)
@@ -3098,20 +3103,20 @@ SymbolFileDWARF::FindTypes (const SymbolContext& sc,
const uint32_t num_matches = types.GetSize() - initial_types_size;
if (log && num_matches)
{
- if (namespace_decl)
+ if (parent_decl_ctx)
{
GetObjectFile()->GetModule()->LogMessage (log,
- "SymbolFileDWARF::FindTypes (sc, name=\"%s\", clang::NamespaceDecl(%p) \"%s\", append=%u, max_matches=%u, type_list) => %u",
+ "SymbolFileDWARF::FindTypes (sc, name=\"%s\", parent_decl_ctx = %p (\"%s\"), append=%u, max_matches=%u, type_list) => %u",
name.GetCString(),
- static_cast<void*>(namespace_decl->GetNamespaceDecl()),
- namespace_decl->GetQualifiedName().c_str(),
+ static_cast<const void*>(parent_decl_ctx),
+ parent_decl_ctx->GetName().AsCString("<NULL>"),
append, max_matches,
num_matches);
}
else
{
GetObjectFile()->GetModule()->LogMessage (log,
- "SymbolFileDWARF::FindTypes (sc, name=\"%s\", clang::NamespaceDecl(NULL), append=%u, max_matches=%u, type_list) => %u",
+ "SymbolFileDWARF::FindTypes (sc, name=\"%s\", parent_decl_ctx = NULL, append=%u, max_matches=%u, type_list) => %u",
name.GetCString(),
append, max_matches,
num_matches);
@@ -3123,10 +3128,10 @@ SymbolFileDWARF::FindTypes (const SymbolContext& sc,
}
-ClangNamespaceDecl
+CompilerDeclContext
SymbolFileDWARF::FindNamespace (const SymbolContext& sc,
const ConstString &name,
- const lldb_private::ClangNamespaceDecl *parent_namespace_decl)
+ const CompilerDeclContext *parent_decl_ctx)
{
Log *log (LogChannelDWARF::GetLogIfAll(DWARF_LOG_LOOKUPS));
@@ -3136,11 +3141,13 @@ SymbolFileDWARF::FindNamespace (const SymbolContext& sc,
"SymbolFileDWARF::FindNamespace (sc, name=\"%s\")",
name.GetCString());
}
-
- if (!NamespaceDeclMatchesThisSymbolFile(parent_namespace_decl))
- return ClangNamespaceDecl();
- ClangNamespaceDecl namespace_decl;
+ CompilerDeclContext namespace_decl_ctx;
+
+ if (!DeclContextMatchesThisSymbolFile(parent_decl_ctx))
+ return namespace_decl_ctx;
+
+
DWARFDebugInfo* info = DebugInfo();
if (info)
{
@@ -3177,23 +3184,16 @@ SymbolFileDWARF::FindNamespace (const SymbolContext& sc,
if (die)
{
- TypeSystem *type_system = GetTypeSystemForLanguage(dwarf_cu->GetLanguageType());
+ if (!DIEInDeclContext(parent_decl_ctx, dwarf_cu, die))
+ continue; // The containing decl contexts don't match
- if (parent_namespace_decl)
- {
- if (type_system && !type_system->DIEIsInNamespace (parent_namespace_decl, this, dwarf_cu, die))
- continue;
- }
+ TypeSystem *type_system = GetTypeSystemForLanguage(dwarf_cu->GetLanguageType());
if (type_system)
{
- clang::NamespaceDecl *clang_namespace_decl = type_system->ResolveNamespaceDIE (this, dwarf_cu, die);
- if (clang_namespace_decl)
- {
- namespace_decl.SetASTContext (GetClangASTContext().getASTContext());
- namespace_decl.SetNamespaceDecl (clang_namespace_decl);
+ namespace_decl_ctx = type_system->GetDeclContextForUIDFromDWARF(this, dwarf_cu, die);
+ if (namespace_decl_ctx)
break;
- }
}
}
else
@@ -3208,16 +3208,17 @@ SymbolFileDWARF::FindNamespace (const SymbolContext& sc,
}
}
}
- if (log && namespace_decl.GetNamespaceDecl())
+ if (log && namespace_decl_ctx)
{
GetObjectFile()->GetModule()->LogMessage (log,
- "SymbolFileDWARF::FindNamespace (sc, name=\"%s\") => clang::NamespaceDecl(%p) \"%s\"",
+ "SymbolFileDWARF::FindNamespace (sc, name=\"%s\") => CompilerDeclContext(%p/%p) \"%s\"",
name.GetCString(),
- static_cast<const void*>(namespace_decl.GetNamespaceDecl()),
- namespace_decl.GetQualifiedName().c_str());
+ static_cast<const void*>(namespace_decl_ctx.GetTypeSystem()),
+ static_cast<const void*>(namespace_decl_ctx.GetOpaqueDeclContext()),
+ namespace_decl_ctx.GetName().AsCString("<NULL>"));
}
- return namespace_decl;
+ return namespace_decl_ctx;
}
uint32_t
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h
index 55c7ce613f1..c9aab353b70 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.h
@@ -90,62 +90,145 @@ public:
static lldb_private::SymbolFile*
CreateInstance (lldb_private::ObjectFile* obj_file);
+
//------------------------------------------------------------------
// Constructors and Destructors
//------------------------------------------------------------------
- SymbolFileDWARF(lldb_private::ObjectFile* ofile);
- ~SymbolFileDWARF() override;
- uint32_t CalculateAbilities () override;
- void InitializeObject() override;
+ SymbolFileDWARF(lldb_private::ObjectFile* ofile);
+
+ ~SymbolFileDWARF() override;
+
+ uint32_t
+ CalculateAbilities () override;
+
+ void
+ InitializeObject() override;
//------------------------------------------------------------------
// Compile Unit function calls
//------------------------------------------------------------------
- uint32_t GetNumCompileUnits() override;
- lldb::CompUnitSP ParseCompileUnitAtIndex(uint32_t index) override;
-
- lldb::LanguageType ParseCompileUnitLanguage (const lldb_private::SymbolContext& sc) override;
- size_t ParseCompileUnitFunctions (const lldb_private::SymbolContext& sc) override;
- bool ParseCompileUnitLineTable (const lldb_private::SymbolContext& sc) override;
- bool ParseCompileUnitSupportFiles (const lldb_private::SymbolContext& sc, lldb_private::FileSpecList& support_files) override;
- bool ParseImportedModules (const lldb_private::SymbolContext &sc, std::vector<lldb_private::ConstString> &imported_modules) override;
- size_t ParseFunctionBlocks (const lldb_private::SymbolContext& sc) override;
- size_t ParseTypes (const lldb_private::SymbolContext& sc) override;
- size_t ParseVariablesForContext (const lldb_private::SymbolContext& sc) override;
-
- lldb_private::Type* ResolveTypeUID(lldb::user_id_t type_uid) override;
- bool CompleteType (lldb_private::CompilerType& clang_type) override;
-
- lldb_private::Type* ResolveType (DWARFCompileUnit* dwarf_cu, const DWARFDebugInfoEntry* type_die, bool assert_not_being_parsed = true);
- lldb_private::Type* GetCachedTypeForDIE (const DWARFDebugInfoEntry* type_die) const;
- void ClearDIEBeingParsed (const DWARFDebugInfoEntry* type_die);
- clang::DeclContext* GetClangDeclContextContainingTypeUID (lldb::user_id_t type_uid) override;
- clang::DeclContext* GetClangDeclContextForTypeUID (const lldb_private::SymbolContext &sc, lldb::user_id_t type_uid) override;
-
- uint32_t ResolveSymbolContext (const lldb_private::Address& so_addr, uint32_t resolve_scope, lldb_private::SymbolContext& sc) override;
- uint32_t ResolveSymbolContext (const lldb_private::FileSpec& file_spec, uint32_t line, bool check_inlines, uint32_t resolve_scope, lldb_private::SymbolContextList& sc_list) override;
- uint32_t FindGlobalVariables(const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, lldb_private::VariableList& variables) override;
- uint32_t FindGlobalVariables(const lldb_private::RegularExpression& regex, bool append, uint32_t max_matches, lldb_private::VariableList& variables) override;
- uint32_t FindFunctions(const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, uint32_t name_type_mask, bool include_inlines, bool append, lldb_private::SymbolContextList& sc_list) override;
- uint32_t FindFunctions(const lldb_private::RegularExpression& regex, bool include_inlines, bool append, lldb_private::SymbolContextList& sc_list) override;
- uint32_t FindTypes (const lldb_private::SymbolContext& sc, const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, lldb_private::TypeList& types) override;
+
+ uint32_t
+ GetNumCompileUnits() override;
+
+ lldb::CompUnitSP
+ ParseCompileUnitAtIndex(uint32_t index) override;
+
+ lldb::LanguageType
+ ParseCompileUnitLanguage (const lldb_private::SymbolContext& sc) override;
+
+ size_t
+ ParseCompileUnitFunctions (const lldb_private::SymbolContext& sc) override;
+
+ bool
+ ParseCompileUnitLineTable (const lldb_private::SymbolContext& sc) override;
+
+ bool
+ ParseCompileUnitSupportFiles (const lldb_private::SymbolContext& sc,
+ lldb_private::FileSpecList& support_files) override;
+
+ bool
+ ParseImportedModules (const lldb_private::SymbolContext &sc,
+ std::vector<lldb_private::ConstString> &imported_modules) override;
+
+ size_t
+ ParseFunctionBlocks (const lldb_private::SymbolContext& sc) override;
+
+ size_t
+ ParseTypes (const lldb_private::SymbolContext& sc) override;
+
+ size_t
+ ParseVariablesForContext (const lldb_private::SymbolContext& sc) override;
+
+ lldb_private::Type *
+ ResolveTypeUID(lldb::user_id_t type_uid) override;
+
+ bool
+ CompleteType (lldb_private::CompilerType& clang_type) override;
+
+ lldb_private::Type *
+ ResolveType (DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry* type_die,
+ bool assert_not_being_parsed = true);
+
+ lldb_private::Type *
+ GetCachedTypeForDIE (const DWARFDebugInfoEntry* type_die) const;
+
+ void
+ ClearDIEBeingParsed (const DWARFDebugInfoEntry* type_die);
+
+ lldb_private::CompilerDeclContext
+ GetDeclContextForUID (lldb::user_id_t uid) override;
+
+ lldb_private::CompilerDeclContext
+ GetDeclContextContainingUID (lldb::user_id_t uid) override;
+
+ uint32_t
+ ResolveSymbolContext (const lldb_private::Address& so_addr,
+ uint32_t resolve_scope,
+ lldb_private::SymbolContext& sc) override;
+
+ uint32_t
+ ResolveSymbolContext (const lldb_private::FileSpec& file_spec,
+ uint32_t line,
+ bool check_inlines,
+ uint32_t resolve_scope,
+ lldb_private::SymbolContextList& sc_list) override;
+
+ uint32_t
+ FindGlobalVariables (const lldb_private::ConstString &name,
+ const lldb_private::CompilerDeclContext *parent_decl_ctx,
+ bool append,
+ uint32_t max_matches,
+ lldb_private::VariableList& variables) override;
+
+ uint32_t
+ FindGlobalVariables (const lldb_private::RegularExpression& regex,
+ bool append,
+ uint32_t max_matches,
+ lldb_private::VariableList& variables) override;
+
+ uint32_t
+ FindFunctions (const lldb_private::ConstString &name,
+ const lldb_private::CompilerDeclContext *parent_decl_ctx,
+ uint32_t name_type_mask,
+ bool include_inlines,
+ bool append,
+ lldb_private::SymbolContextList& sc_list) override;
+
+ uint32_t
+ FindFunctions (const lldb_private::RegularExpression& regex,
+ bool include_inlines,
+ bool append,
+ lldb_private::SymbolContextList& sc_list) override;
+
+ uint32_t
+ FindTypes (const lldb_private::SymbolContext& sc,
+ const lldb_private::ConstString &name,
+ const lldb_private::CompilerDeclContext *parent_decl_ctx,
+ bool append,
+ uint32_t max_matches,
+ lldb_private::TypeList& types) override;
+
lldb_private::TypeList *
- GetTypeList () override;
- size_t GetTypes (lldb_private::SymbolContextScope *sc_scope,
- uint32_t type_mask,
- lldb_private::TypeList &type_list) override;
+ GetTypeList () override;
+
+ size_t
+ GetTypes (lldb_private::SymbolContextScope *sc_scope,
+ uint32_t type_mask,
+ lldb_private::TypeList &type_list) override;
lldb_private::ClangASTContext &
- GetClangASTContext () override;
+ GetClangASTContext () override;
lldb_private::TypeSystem *
- GetTypeSystemForLanguage (lldb::LanguageType language) override;
+ GetTypeSystemForLanguage (lldb::LanguageType language) override;
- lldb_private::ClangNamespaceDecl
- FindNamespace (const lldb_private::SymbolContext& sc,
- const lldb_private::ConstString &name,
- const lldb_private::ClangNamespaceDecl *parent_namespace_decl) override;
+ lldb_private::CompilerDeclContext
+ FindNamespace (const lldb_private::SymbolContext& sc,
+ const lldb_private::ConstString &name,
+ const lldb_private::CompilerDeclContext *parent_decl_ctx) override;
//------------------------------------------------------------------
@@ -171,14 +254,22 @@ public:
const lldb_private::DWARFDataExtractor& get_apple_objc_data ();
- DWARFDebugAbbrev* DebugAbbrev();
- const DWARFDebugAbbrev* DebugAbbrev() const;
+ DWARFDebugAbbrev*
+ DebugAbbrev();
+
+ const DWARFDebugAbbrev*
+ DebugAbbrev() const;
- DWARFDebugInfo* DebugInfo();
- const DWARFDebugInfo* DebugInfo() const;
+ DWARFDebugInfo*
+ DebugInfo();
- DWARFDebugRanges* DebugRanges();
- const DWARFDebugRanges* DebugRanges() const;
+ const DWARFDebugInfo*
+ DebugInfo() const;
+
+ DWARFDebugRanges*
+ DebugRanges();
+ const DWARFDebugRanges*
+ DebugRanges() const;
const lldb_private::DWARFDataExtractor&
GetCachedSectionData (uint32_t got_flag,
@@ -189,7 +280,8 @@ public:
SupportedVersion(uint16_t version);
const DWARFDebugInfoEntry *
- GetDeclContextDIEContainingDIE (const DWARFCompileUnit *cu, const DWARFDebugInfoEntry *die);
+ GetDeclContextDIEContainingDIE (const DWARFCompileUnit *cu,
+ const DWARFDebugInfoEntry *die);
lldb_private::Flags&
GetFlags ()
@@ -207,7 +299,8 @@ public:
HasForwardDeclForClangType (const lldb_private::CompilerType &clang_type);
lldb_private::CompileUnit*
- GetCompUnitForDWARFCompUnit(DWARFCompileUnit* dwarf_cu, uint32_t cu_idx = UINT32_MAX);
+ GetCompUnitForDWARFCompUnit(DWARFCompileUnit* dwarf_cu,
+ uint32_t cu_idx = UINT32_MAX);
lldb::user_id_t
MakeUserID (dw_offset_t die_offset) const
@@ -216,7 +309,8 @@ public:
}
size_t
- GetObjCMethodDIEOffsets (lldb_private::ConstString class_name, DIEArray &method_die_offsets);
+ GetObjCMethodDIEOffsets (lldb_private::ConstString class_name,
+ DIEArray &method_die_offsets);
bool
Supports_DW_AT_APPLE_objc_complete_type (DWARFCompileUnit *cu);
@@ -245,123 +339,174 @@ protected:
flagsGotAppleObjCData = (1 << 14)
};
- bool NamespaceDeclMatchesThisSymbolFile (const lldb_private::ClangNamespaceDecl *namespace_decl);
+ bool
+ DeclContextMatchesThisSymbolFile (const lldb_private::CompilerDeclContext *decl_ctx);
+
+ bool
+ DIEInDeclContext (const lldb_private::CompilerDeclContext *parent_decl_ctx,
+ DWARFCompileUnit *cu,
+ const DWARFDebugInfoEntry *die);
DISALLOW_COPY_AND_ASSIGN (SymbolFileDWARF);
- lldb::CompUnitSP ParseCompileUnit (DWARFCompileUnit* dwarf_cu, uint32_t cu_idx);
- DWARFCompileUnit* GetDWARFCompileUnit(lldb_private::CompileUnit *comp_unit);
- DWARFCompileUnit* GetNextUnparsedDWARFCompileUnit(DWARFCompileUnit* prev_cu);
- bool GetFunction (DWARFCompileUnit* dwarf_cu, const DWARFDebugInfoEntry* func_die, lldb_private::SymbolContext& sc);
- lldb_private::Function * ParseCompileUnitFunction (const lldb_private::SymbolContext& sc, DWARFCompileUnit* dwarf_cu, const DWARFDebugInfoEntry *die);
- size_t ParseFunctionBlocks (const lldb_private::SymbolContext& sc,
- lldb_private::Block *parent_block,
- DWARFCompileUnit* dwarf_cu,
- const DWARFDebugInfoEntry *die,
- lldb::addr_t subprogram_low_pc,
- uint32_t depth);
- size_t ParseTypes (const lldb_private::SymbolContext& sc, DWARFCompileUnit* dwarf_cu, const DWARFDebugInfoEntry *die, bool parse_siblings, bool parse_children);
- lldb::TypeSP ParseType (const lldb_private::SymbolContext& sc, DWARFCompileUnit* dwarf_cu, const DWARFDebugInfoEntry *die, bool *type_is_new);
- lldb_private::Type* ResolveTypeUID (DWARFCompileUnit* dwarf_cu, const DWARFDebugInfoEntry* die, bool assert_not_being_parsed);
-
- lldb::VariableSP ParseVariableDIE(
- const lldb_private::SymbolContext& sc,
- DWARFCompileUnit* dwarf_cu,
- const DWARFDebugInfoEntry *die,
- const lldb::addr_t func_low_pc);
-
- size_t ParseVariables(
- const lldb_private::SymbolContext& sc,
- DWARFCompileUnit* dwarf_cu,
- const lldb::addr_t func_low_pc,
- const DWARFDebugInfoEntry *die,
- bool parse_siblings,
- bool parse_children,
- lldb_private::VariableList* cc_variable_list = NULL);
-
- bool ClassOrStructIsVirtual (
- DWARFCompileUnit* dwarf_cu,
- const DWARFDebugInfoEntry *parent_die);
-
- // Given a die_offset, figure out the symbol context representing that die.
- bool ResolveFunction (dw_offset_t offset,
- DWARFCompileUnit *&dwarf_cu,
- bool include_inlines,
- lldb_private::SymbolContextList& sc_list);
-
- bool ResolveFunction (DWARFCompileUnit *cu,
- const DWARFDebugInfoEntry *die,
- bool include_inlines,
- lldb_private::SymbolContextList& sc_list);
-
- bool FunctionDieMatchesPartialName (
- const DWARFDebugInfoEntry* die,
- const DWARFCompileUnit *dwarf_cu,
- uint32_t name_type_mask,
- const char *partial_name,
- const char *base_name_start,
- const char *base_name_end);
-
- void FindFunctions(
- const lldb_private::ConstString &name,
- const NameToDIE &name_to_die,
- bool include_inlines,
- lldb_private::SymbolContextList& sc_list);
-
- void FindFunctions (
- const lldb_private::RegularExpression &regex,
- const NameToDIE &name_to_die,
- bool include_inlines,
- lldb_private::SymbolContextList& sc_list);
-
- void FindFunctions (
- const lldb_private::RegularExpression &regex,
- const DWARFMappedHash::MemoryTable &memory_table,
- bool include_inlines,
- lldb_private::SymbolContextList& sc_list);
-
- lldb::TypeSP FindDefinitionTypeForDWARFDeclContext (
- const DWARFDeclContext &die_decl_ctx);
-
- lldb::TypeSP FindCompleteObjCDefinitionTypeForDIE (
- const DWARFDebugInfoEntry *die,
- const lldb_private::ConstString &type_name,
- bool must_be_implementation);
-
- lldb::TypeSP FindCompleteObjCDefinitionType (const lldb_private::ConstString &type_name,
- bool header_definition_ok);
-
- lldb_private::Symbol * GetObjCClassSymbol (const lldb_private::ConstString &objc_class_name);
-
- void ParseFunctions (const DIEArray &die_offsets,
- bool include_inlines,
- lldb_private::SymbolContextList& sc_list);
- lldb::TypeSP GetTypeForDIE (DWARFCompileUnit *cu,
- const DWARFDebugInfoEntry* die);
-
- uint32_t FindTypes(std::vector<dw_offset_t> die_offsets, uint32_t max_matches, lldb_private::TypeList& types);
-
- void Index();
-
- void DumpIndexes();
- void SetDebugMapModule (const lldb::ModuleSP &module_sp)
- {
- m_debug_map_module_wp = module_sp;
- }
+ lldb::CompUnitSP
+ ParseCompileUnit (DWARFCompileUnit* dwarf_cu,
+ uint32_t cu_idx);
+
+ DWARFCompileUnit*
+ GetDWARFCompileUnit (lldb_private::CompileUnit *comp_unit);
+
+ DWARFCompileUnit*
+ GetNextUnparsedDWARFCompileUnit (DWARFCompileUnit* prev_cu);
+
+ bool
+ GetFunction (DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry* func_die,
+ lldb_private::SymbolContext& sc);
+
+ lldb_private::Function *
+ ParseCompileUnitFunction (const lldb_private::SymbolContext& sc,
+ DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry *die);
+
+ size_t
+ ParseFunctionBlocks (const lldb_private::SymbolContext& sc,
+ lldb_private::Block *parent_block,
+ DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry *die,
+ lldb::addr_t subprogram_low_pc,
+ uint32_t depth);
+
+ size_t
+ ParseTypes (const lldb_private::SymbolContext& sc,
+ DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry *die,
+ bool parse_siblings,
+ bool parse_children);
+
+ lldb::TypeSP
+ ParseType (const lldb_private::SymbolContext& sc,
+ DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry *die,
+ bool *type_is_new);
+
+ lldb_private::Type *
+ ResolveTypeUID (DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry* die,
+ bool assert_not_being_parsed);
+
+ lldb::VariableSP
+ ParseVariableDIE(const lldb_private::SymbolContext& sc,
+ DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry *die,
+ const lldb::addr_t func_low_pc);
+
+ size_t
+ ParseVariables(const lldb_private::SymbolContext& sc,
+ DWARFCompileUnit* dwarf_cu,
+ const lldb::addr_t func_low_pc,
+ const DWARFDebugInfoEntry *die,
+ bool parse_siblings,
+ bool parse_children,
+ lldb_private::VariableList* cc_variable_list = NULL);
+
+ bool
+ ClassOrStructIsVirtual (DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry *parent_die);
+
+ // Given a die_offset, figure out the symbol context representing that die.
+ bool
+ ResolveFunction (dw_offset_t offset,
+ DWARFCompileUnit *&dwarf_cu,
+ bool include_inlines,
+ lldb_private::SymbolContextList& sc_list);
+
+ bool
+ ResolveFunction (DWARFCompileUnit *cu,
+ const DWARFDebugInfoEntry *die,
+ bool include_inlines,
+ lldb_private::SymbolContextList& sc_list);
+
+ bool
+ FunctionDieMatchesPartialName (const DWARFDebugInfoEntry* die,
+ const DWARFCompileUnit *dwarf_cu,
+ uint32_t name_type_mask,
+ const char *partial_name,
+ const char *base_name_start,
+ const char *base_name_end);
+
+ void
+ FindFunctions(const lldb_private::ConstString &name,
+ const NameToDIE &name_to_die,
+ bool include_inlines,
+ lldb_private::SymbolContextList& sc_list);
+
+ void
+ FindFunctions (const lldb_private::RegularExpression &regex,
+ const NameToDIE &name_to_die,
+ bool include_inlines,
+ lldb_private::SymbolContextList& sc_list);
+
+ void
+ FindFunctions (const lldb_private::RegularExpression &regex,
+ const DWARFMappedHash::MemoryTable &memory_table,
+ bool include_inlines,
+ lldb_private::SymbolContextList& sc_list);
+
+ lldb::TypeSP
+ FindDefinitionTypeForDWARFDeclContext (const DWARFDeclContext &die_decl_ctx);
+
+ lldb::TypeSP
+ FindCompleteObjCDefinitionTypeForDIE (const DWARFDebugInfoEntry *die,
+ const lldb_private::ConstString &type_name,
+ bool must_be_implementation);
+
+ lldb::TypeSP
+ FindCompleteObjCDefinitionType (const lldb_private::ConstString &type_name,
+ bool header_definition_ok);
+
+ lldb_private::Symbol *
+ GetObjCClassSymbol (const lldb_private::ConstString &objc_class_name);
+
+ void
+ ParseFunctions (const DIEArray &die_offsets,
+ bool include_inlines,
+ lldb_private::SymbolContextList& sc_list);
+
+ lldb::TypeSP
+ GetTypeForDIE (DWARFCompileUnit *cu,
+ const DWARFDebugInfoEntry* die);
+
+ uint32_t
+ FindTypes (std::vector<dw_offset_t> die_offsets,
+ uint32_t max_matches,
+ lldb_private::TypeList& types);
+
+ void
+ Index();
+ void
+ DumpIndexes();
+
+ void
+ SetDebugMapModule (const lldb::ModuleSP &module_sp)
+ {
+ m_debug_map_module_wp = module_sp;
+ }
+
SymbolFileDWARFDebugMap *
- GetDebugMapSymfile ();
+ GetDebugMapSymfile ();
const DWARFDebugInfoEntry *
- FindBlockContainingSpecification (dw_offset_t func_die_offset,
- dw_offset_t spec_block_die_offset,
- DWARFCompileUnit **dwarf_cu_handle);
+ FindBlockContainingSpecification (dw_offset_t func_die_offset,
+ dw_offset_t spec_block_die_offset,
+ DWARFCompileUnit **dwarf_cu_handle);
const DWARFDebugInfoEntry *
- FindBlockContainingSpecification (DWARFCompileUnit* dwarf_cu,
- const DWARFDebugInfoEntry *die,
- dw_offset_t spec_block_die_offset,
- DWARFCompileUnit **dwarf_cu_handle);
+ FindBlockContainingSpecification (DWARFCompileUnit* dwarf_cu,
+ const DWARFDebugInfoEntry *die,
+ dw_offset_t spec_block_die_offset,
+ DWARFCompileUnit **dwarf_cu_handle);
UniqueDWARFASTTypeMap &
GetUniqueDWARFASTTypeMap ();
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
index e2ab962a948..dc0c42e22a0 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
@@ -877,7 +877,7 @@ uint32_t
SymbolFileDWARFDebugMap::PrivateFindGlobalVariables
(
const ConstString &name,
- const ClangNamespaceDecl *namespace_decl,
+ const CompilerDeclContext *parent_decl_ctx,
const std::vector<uint32_t> &indexes, // Indexes into the symbol table that match "name"
uint32_t max_matches,
VariableList& variables
@@ -894,7 +894,7 @@ SymbolFileDWARFDebugMap::PrivateFindGlobalVariables
SymbolFileDWARF *oso_dwarf = GetSymbolFileByOSOIndex (oso_idx);
if (oso_dwarf)
{
- if (oso_dwarf->FindGlobalVariables(name, namespace_decl, true, max_matches, variables))
+ if (oso_dwarf->FindGlobalVariables(name, parent_decl_ctx, true, max_matches, variables))
if (variables.GetSize() > max_matches)
break;
}
@@ -904,7 +904,11 @@ SymbolFileDWARFDebugMap::PrivateFindGlobalVariables
}
uint32_t
-SymbolFileDWARFDebugMap::FindGlobalVariables (const ConstString &name, const ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, VariableList& variables)
+SymbolFileDWARFDebugMap::FindGlobalVariables (const ConstString &name,
+ const CompilerDeclContext *parent_decl_ctx,
+ bool append,
+ uint32_t max_matches,
+ VariableList& variables)
{
// If we aren't appending the results to this list, then clear the list
@@ -919,7 +923,7 @@ SymbolFileDWARFDebugMap::FindGlobalVariables (const ConstString &name, const Cla
ForEachSymbolFile([&](SymbolFileDWARF *oso_dwarf) -> bool {
const uint32_t oso_matches = oso_dwarf->FindGlobalVariables (name,
- namespace_decl,
+ parent_decl_ctx,
true,
max_matches,
variables);
@@ -1097,7 +1101,12 @@ RemoveFunctionsWithModuleNotEqualTo (const ModuleSP &module_sp, SymbolContextLis
}
uint32_t
-SymbolFileDWARFDebugMap::FindFunctions(const ConstString &name, const ClangNamespaceDecl *namespace_decl, uint32_t name_type_mask, bool include_inlines, bool append, SymbolContextList& sc_list)
+SymbolFileDWARFDebugMap::FindFunctions(const ConstString &name,
+ const CompilerDeclContext *parent_decl_ctx,
+ uint32_t name_type_mask,
+ bool include_inlines,
+ bool append,
+ SymbolContextList& sc_list)
{
Timer scoped_timer (__PRETTY_FUNCTION__,
"SymbolFileDWARFDebugMap::FindFunctions (name = %s)",
@@ -1111,7 +1120,7 @@ SymbolFileDWARFDebugMap::FindFunctions(const ConstString &name, const ClangNames
ForEachSymbolFile([&](SymbolFileDWARF *oso_dwarf) -> bool {
uint32_t sc_idx = sc_list.GetSize();
- if (oso_dwarf->FindFunctions(name, namespace_decl, name_type_mask, include_inlines, true, sc_list))
+ if (oso_dwarf->FindFunctions(name, parent_decl_ctx, name_type_mask, include_inlines, true, sc_list))
{
RemoveFunctionsWithModuleNotEqualTo (m_obj_file->GetModule(), sc_list, sc_idx);
}
@@ -1286,8 +1295,8 @@ SymbolFileDWARFDebugMap::FindTypes
(
const SymbolContext& sc,
const ConstString &name,
- const ClangNamespaceDecl *namespace_decl,
- bool append,
+ const CompilerDeclContext *parent_decl_ctx,
+ bool append,
uint32_t max_matches,
TypeList& types
)
@@ -1302,12 +1311,12 @@ SymbolFileDWARFDebugMap::FindTypes
{
oso_dwarf = GetSymbolFile (sc);
if (oso_dwarf)
- return oso_dwarf->FindTypes (sc, name, namespace_decl, append, max_matches, types);
+ return oso_dwarf->FindTypes (sc, name, parent_decl_ctx, append, max_matches, types);
}
else
{
ForEachSymbolFile([&](SymbolFileDWARF *oso_dwarf) -> bool {
- oso_dwarf->FindTypes (sc, name, namespace_decl, append, max_matches, types);
+ oso_dwarf->FindTypes (sc, name, parent_decl_ctx, append, max_matches, types);
return false;
});
}
@@ -1326,24 +1335,24 @@ SymbolFileDWARFDebugMap::FindTypes
//}
-ClangNamespaceDecl
+CompilerDeclContext
SymbolFileDWARFDebugMap::FindNamespace (const lldb_private::SymbolContext& sc,
const lldb_private::ConstString &name,
- const ClangNamespaceDecl *parent_namespace_decl)
+ const CompilerDeclContext *parent_decl_ctx)
{
- ClangNamespaceDecl matching_namespace;
+ CompilerDeclContext matching_namespace;
SymbolFileDWARF *oso_dwarf;
if (sc.comp_unit)
{
oso_dwarf = GetSymbolFile (sc);
if (oso_dwarf)
- matching_namespace = oso_dwarf->FindNamespace (sc, name, parent_namespace_decl);
+ matching_namespace = oso_dwarf->FindNamespace (sc, name, parent_decl_ctx);
}
else
{
ForEachSymbolFile([&](SymbolFileDWARF *oso_dwarf) -> bool {
- matching_namespace = oso_dwarf->FindNamespace (sc, name, parent_namespace_decl);
+ matching_namespace = oso_dwarf->FindNamespace (sc, name, parent_decl_ctx);
return (bool)matching_namespace;
});
@@ -1433,24 +1442,24 @@ SymbolFileDWARFDebugMap::SetCompileUnit (SymbolFileDWARF *oso_dwarf, const CompU
}
}
-clang::DeclContext*
-SymbolFileDWARFDebugMap::GetClangDeclContextContainingTypeUID (lldb::user_id_t type_uid)
+CompilerDeclContext
+SymbolFileDWARFDebugMap::GetDeclContextForUID (lldb::user_id_t type_uid)
{
const uint64_t oso_idx = GetOSOIndexFromUserID (type_uid);
SymbolFileDWARF *oso_dwarf = GetSymbolFileByOSOIndex (oso_idx);
if (oso_dwarf)
- return oso_dwarf->GetClangDeclContextContainingTypeUID (type_uid);
- return NULL;
+ return oso_dwarf->GetDeclContextForUID (type_uid);
+ return CompilerDeclContext();
}
-clang::DeclContext*
-SymbolFileDWARFDebugMap::GetClangDeclContextForTypeUID (const lldb_private::SymbolContext &sc, lldb::user_id_t type_uid)
+CompilerDeclContext
+SymbolFileDWARFDebugMap::GetDeclContextContainingUID (lldb::user_id_t type_uid)
{
const uint64_t oso_idx = GetOSOIndexFromUserID (type_uid);
SymbolFileDWARF *oso_dwarf = GetSymbolFileByOSOIndex (oso_idx);
if (oso_dwarf)
- return oso_dwarf->GetClangDeclContextForTypeUID (sc, type_uid);
- return NULL;
+ return oso_dwarf->GetDeclContextContainingUID (type_uid);
+ return CompilerDeclContext();
}
bool
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h
index 2fc5d047f54..fb4d1f88264 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.h
@@ -75,20 +75,20 @@ public:
size_t ParseVariablesForContext (const lldb_private::SymbolContext& sc) override;
lldb_private::Type* ResolveTypeUID (lldb::user_id_t type_uid) override;
- clang::DeclContext* GetClangDeclContextContainingTypeUID (lldb::user_id_t type_uid) override;
- clang::DeclContext* GetClangDeclContextForTypeUID (const lldb_private::SymbolContext &sc, lldb::user_id_t type_uid) override;
+ lldb_private::CompilerDeclContext GetDeclContextForUID (lldb::user_id_t uid) override;
+ lldb_private::CompilerDeclContext GetDeclContextContainingUID (lldb::user_id_t uid) override;
bool CompleteType (lldb_private::CompilerType& clang_type) override;
uint32_t ResolveSymbolContext (const lldb_private::Address& so_addr, uint32_t resolve_scope, lldb_private::SymbolContext& sc) override;
uint32_t ResolveSymbolContext (const lldb_private::FileSpec& file_spec, uint32_t line, bool check_inlines, uint32_t resolve_scope, lldb_private::SymbolContextList& sc_list) override;
- uint32_t FindGlobalVariables (const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, lldb_private::VariableList& variables) override;
+ uint32_t FindGlobalVariables (const lldb_private::ConstString &name, const lldb_private::CompilerDeclContext *parent_decl_ctx, bool append, uint32_t max_matches, lldb_private::VariableList& variables) override;
uint32_t FindGlobalVariables (const lldb_private::RegularExpression& regex, bool append, uint32_t max_matches, lldb_private::VariableList& variables) override;
- uint32_t FindFunctions (const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, uint32_t name_type_mask, bool include_inlines, bool append, lldb_private::SymbolContextList& sc_list) override;
+ uint32_t FindFunctions (const lldb_private::ConstString &name, const lldb_private::CompilerDeclContext *parent_decl_ctx, uint32_t name_type_mask, bool include_inlines, bool append, lldb_private::SymbolContextList& sc_list) override;
uint32_t FindFunctions (const lldb_private::RegularExpression& regex, bool include_inlines, bool append, lldb_private::SymbolContextList& sc_list) override;
- uint32_t FindTypes (const lldb_private::SymbolContext& sc, const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, lldb_private::TypeList& types) override;
- lldb_private::ClangNamespaceDecl
+ uint32_t FindTypes (const lldb_private::SymbolContext& sc, const lldb_private::ConstString &name, const lldb_private::CompilerDeclContext *parent_decl_ctx, bool append, uint32_t max_matches, lldb_private::TypeList& types) override;
+ lldb_private::CompilerDeclContext
FindNamespace (const lldb_private::SymbolContext& sc,
const lldb_private::ConstString &name,
- const lldb_private::ClangNamespaceDecl *parent_namespace_decl) override;
+ const lldb_private::CompilerDeclContext *parent_decl_ctx) override;
size_t GetTypes (lldb_private::SymbolContextScope *sc_scope,
uint32_t type_mask,
lldb_private::TypeList &type_list) override;
@@ -244,7 +244,7 @@ protected:
uint32_t
PrivateFindGlobalVariables (const lldb_private::ConstString &name,
- const lldb_private::ClangNamespaceDecl *namespace_decl,
+ const lldb_private::CompilerDeclContext *parent_decl_ctx,
const std::vector<uint32_t> &name_symbol_indexes,
uint32_t max_matches,
lldb_private::VariableList& variables);
diff --git a/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp b/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp
index 5308db393c0..edbe7379a86 100644
--- a/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp
+++ b/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp
@@ -305,12 +305,6 @@ SymbolFileSymtab::CompleteType (lldb_private::CompilerType& clang_opaque_type)
return false;
}
-ClangNamespaceDecl
-SymbolFileSymtab::FindNamespace (const SymbolContext& sc, const ConstString &name, const ClangNamespaceDecl *namespace_decl)
-{
- return ClangNamespaceDecl();
-}
-
uint32_t
SymbolFileSymtab::ResolveSymbolContext (const Address& so_addr, uint32_t resolve_scope, SymbolContext& sc)
{
@@ -327,63 +321,6 @@ SymbolFileSymtab::ResolveSymbolContext (const Address& so_addr, uint32_t resolve
return resolved_flags;
}
-uint32_t
-SymbolFileSymtab::ResolveSymbolContext (const FileSpec& file_spec, uint32_t line, bool check_inlines, uint32_t resolve_scope, SymbolContextList& sc_list)
-{
- return 0;
-}
-
-uint32_t
-SymbolFileSymtab::FindGlobalVariables(const ConstString &name, const ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, VariableList& variables)
-{
- return 0;
-}
-
-uint32_t
-SymbolFileSymtab::FindGlobalVariables(const RegularExpression& regex, bool append, uint32_t max_matches, VariableList& variables)
-{
- return 0;
-}
-
-uint32_t
-SymbolFileSymtab::FindFunctions(const ConstString &name, const ClangNamespaceDecl *namespace_decl, uint32_t name_type_mask, bool include_inlines, bool append, SymbolContextList& sc_list)
-{
- Timer scoped_timer (__PRETTY_FUNCTION__,
- "SymbolFileSymtab::FindFunctions (name = '%s')",
- name.GetCString());
- // If we ever support finding STABS or COFF debug info symbols,
- // we will need to add support here. We are not trying to find symbols
- // here, just "lldb_private::Function" objects that come from complete
- // debug information. Any symbol queries should go through the symbol
- // table itself in the module's object file.
- return 0;
-}
-
-uint32_t
-SymbolFileSymtab::FindFunctions(const RegularExpression& regex, bool include_inlines, bool append, SymbolContextList& sc_list)
-{
- Timer scoped_timer (__PRETTY_FUNCTION__,
- "SymbolFileSymtab::FindFunctions (regex = '%s')",
- regex.GetText());
- // If we ever support finding STABS or COFF debug info symbols,
- // we will need to add support here. We are not trying to find symbols
- // here, just "lldb_private::Function" objects that come from complete
- // debug information. Any symbol queries should go through the symbol
- // table itself in the module's object file.
- return 0;
-}
-
-uint32_t
-SymbolFileSymtab::FindTypes (const lldb_private::SymbolContext& sc,
- const lldb_private::ConstString &name,
- const ClangNamespaceDecl *namespace_decl,
- bool append,
- uint32_t max_matches,
- lldb_private::TypeList& types)
-{
- return 0;
-}
-
//------------------------------------------------------------------
// PluginInterface protocol
//------------------------------------------------------------------
diff --git a/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.h b/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.h
index 8ff2181a414..624bf40914e 100644
--- a/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.h
+++ b/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.h
@@ -87,34 +87,11 @@ public:
virtual uint32_t
ResolveSymbolContext (const lldb_private::Address& so_addr, uint32_t resolve_scope, lldb_private::SymbolContext& sc);
- virtual uint32_t
- ResolveSymbolContext (const lldb_private::FileSpec& file_spec, uint32_t line, bool check_inlines, uint32_t resolve_scope, lldb_private::SymbolContextList& sc_list);
-
- virtual uint32_t
- FindGlobalVariables(const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, lldb_private::VariableList& variables);
-
- virtual uint32_t
- FindGlobalVariables(const lldb_private::RegularExpression& regex, bool append, uint32_t max_matches, lldb_private::VariableList& variables);
-
- virtual uint32_t
- FindFunctions(const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, uint32_t name_type_mask, bool include_inlines, bool append, lldb_private::SymbolContextList& sc_list);
-
- virtual uint32_t
- FindFunctions(const lldb_private::RegularExpression& regex, bool include_inlines, bool append, lldb_private::SymbolContextList& sc_list);
-
- virtual uint32_t
- FindTypes (const lldb_private::SymbolContext& sc,const lldb_private::ConstString &name, const lldb_private::ClangNamespaceDecl *namespace_decl, bool append, uint32_t max_matches, lldb_private::TypeList& types);
-
virtual size_t
GetTypes (lldb_private::SymbolContextScope *sc_scope,
uint32_t type_mask,
lldb_private::TypeList &type_list);
- virtual lldb_private::ClangNamespaceDecl
- FindNamespace (const lldb_private::SymbolContext& sc,
- const lldb_private::ConstString &name,
- const lldb_private::ClangNamespaceDecl *parent_namespace_decl);
-
//------------------------------------------------------------------
// PluginInterface protocol
//------------------------------------------------------------------
diff --git a/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetItemInfoHandler.cpp b/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetItemInfoHandler.cpp
index bd5cf2b44bb..a882b7e3e87 100644
--- a/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetItemInfoHandler.cpp
+++ b/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetItemInfoHandler.cpp
@@ -298,25 +298,25 @@ AppleGetItemInfoHandler::GetItemInfo (Thread &thread, uint64_t item, addr_t page
CompilerType clang_void_ptr_type = clang_ast_context->GetBasicType(eBasicTypeVoid).GetPointerType();
Value return_buffer_ptr_value;
return_buffer_ptr_value.SetValueType (Value::eValueTypeScalar);
- return_buffer_ptr_value.SetClangType (clang_void_ptr_type);
+ return_buffer_ptr_value.SetCompilerType (clang_void_ptr_type);
CompilerType clang_int_type = clang_ast_context->GetBasicType(eBasicTypeInt);
Value debug_value;
debug_value.SetValueType (Value::eValueTypeScalar);
- debug_value.SetClangType (clang_int_type);
+ debug_value.SetCompilerType (clang_int_type);
CompilerType clang_uint64_type = clang_ast_context->GetBasicType(eBasicTypeUnsignedLongLong);
Value item_value;
item_value.SetValueType (Value::eValueTypeScalar);
- item_value.SetClangType (clang_uint64_type);
+ item_value.SetCompilerType (clang_uint64_type);
Value page_to_free_value;
page_to_free_value.SetValueType (Value::eValueTypeScalar);
- page_to_free_value.SetClangType (clang_void_ptr_type);
+ page_to_free_value.SetCompilerType (clang_void_ptr_type);
Value page_to_free_size_value;
page_to_free_size_value.SetValueType (Value::eValueTypeScalar);
- page_to_free_size_value.SetClangType (clang_uint64_type);
+ page_to_free_size_value.SetCompilerType (clang_uint64_type);
Mutex::Locker locker(m_get_item_info_retbuffer_mutex);
diff --git a/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetPendingItemsHandler.cpp b/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetPendingItemsHandler.cpp
index 98cf4ca8fdc..c3e68eaa0a6 100644
--- a/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetPendingItemsHandler.cpp
+++ b/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetPendingItemsHandler.cpp
@@ -304,25 +304,25 @@ AppleGetPendingItemsHandler::GetPendingItems (Thread &thread, addr_t queue, addr
CompilerType clang_void_ptr_type = clang_ast_context->GetBasicType(eBasicTypeVoid).GetPointerType();
Value return_buffer_ptr_value;
return_buffer_ptr_value.SetValueType (Value::eValueTypeScalar);
- return_buffer_ptr_value.SetClangType (clang_void_ptr_type);
+ return_buffer_ptr_value.SetCompilerType (clang_void_ptr_type);
CompilerType clang_int_type = clang_ast_context->GetBasicType(eBasicTypeInt);
Value debug_value;
debug_value.SetValueType (Value::eValueTypeScalar);
- debug_value.SetClangType (clang_int_type);
+ debug_value.SetCompilerType (clang_int_type);
CompilerType clang_uint64_type = clang_ast_context->GetBasicType(eBasicTypeUnsignedLongLong);
Value queue_value;
queue_value.SetValueType (Value::eValueTypeScalar);
- queue_value.SetClangType (clang_uint64_type);
+ queue_value.SetCompilerType (clang_uint64_type);
Value page_to_free_value;
page_to_free_value.SetValueType (Value::eValueTypeScalar);
- page_to_free_value.SetClangType (clang_void_ptr_type);
+ page_to_free_value.SetCompilerType (clang_void_ptr_type);
Value page_to_free_size_value;
page_to_free_size_value.SetValueType (Value::eValueTypeScalar);
- page_to_free_size_value.SetClangType (clang_uint64_type);
+ page_to_free_size_value.SetCompilerType (clang_uint64_type);
Mutex::Locker locker(m_get_pending_items_retbuffer_mutex);
diff --git a/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetQueuesHandler.cpp b/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetQueuesHandler.cpp
index 0c76f4f1a9a..1d9dac5b161 100644
--- a/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetQueuesHandler.cpp
+++ b/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetQueuesHandler.cpp
@@ -311,21 +311,21 @@ AppleGetQueuesHandler::GetCurrentQueues (Thread &thread, addr_t page_to_free, ui
CompilerType clang_void_ptr_type = clang_ast_context->GetBasicType(eBasicTypeVoid).GetPointerType();
Value return_buffer_ptr_value;
return_buffer_ptr_value.SetValueType (Value::eValueTypeScalar);
- return_buffer_ptr_value.SetClangType (clang_void_ptr_type);
+ return_buffer_ptr_value.SetCompilerType (clang_void_ptr_type);
CompilerType clang_int_type = clang_ast_context->GetBasicType(eBasicTypeInt);
Value debug_value;
debug_value.SetValueType (Value::eValueTypeScalar);
- debug_value.SetClangType (clang_int_type);
+ debug_value.SetCompilerType (clang_int_type);
Value page_to_free_value;
page_to_free_value.SetValueType (Value::eValueTypeScalar);
- page_to_free_value.SetClangType (clang_void_ptr_type);
+ page_to_free_value.SetCompilerType (clang_void_ptr_type);
CompilerType clang_uint64_type = clang_ast_context->GetBasicType(eBasicTypeUnsignedLongLong);
Value page_to_free_size_value;
page_to_free_size_value.SetValueType (Value::eValueTypeScalar);
- page_to_free_size_value.SetClangType (clang_uint64_type);
+ page_to_free_size_value.SetCompilerType (clang_uint64_type);
Mutex::Locker locker(m_get_queues_retbuffer_mutex);
diff --git a/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetThreadItemInfoHandler.cpp b/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetThreadItemInfoHandler.cpp
index 78511e0777e..2509b3ba0ef 100644
--- a/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetThreadItemInfoHandler.cpp
+++ b/lldb/source/Plugins/SystemRuntime/MacOSX/AppleGetThreadItemInfoHandler.cpp
@@ -301,25 +301,25 @@ AppleGetThreadItemInfoHandler::GetThreadItemInfo (Thread &thread, tid_t thread_i
CompilerType clang_void_ptr_type = clang_ast_context->GetBasicType(eBasicTypeVoid).GetPointerType();
Value return_buffer_ptr_value;
return_buffer_ptr_value.SetValueType (Value::eValueTypeScalar);
- return_buffer_ptr_value.SetClangType (clang_void_ptr_type);
+ return_buffer_ptr_value.SetCompilerType (clang_void_ptr_type);
CompilerType clang_int_type = clang_ast_context->GetBasicType(eBasicTypeInt);
Value debug_value;
debug_value.SetValueType (Value::eValueTypeScalar);
- debug_value.SetClangType (clang_int_type);
+ debug_value.SetCompilerType (clang_int_type);
CompilerType clang_uint64_type = clang_ast_context->GetBasicType(eBasicTypeUnsignedLongLong);
Value thread_id_value;
thread_id_value.SetValueType (Value::eValueTypeScalar);
- thread_id_value.SetClangType (clang_uint64_type);
+ thread_id_value.SetCompilerType (clang_uint64_type);
Value page_to_free_value;
page_to_free_value.SetValueType (Value::eValueTypeScalar);
- page_to_free_value.SetClangType (clang_void_ptr_type);
+ page_to_free_value.SetCompilerType (clang_void_ptr_type);
Value page_to_free_size_value;
page_to_free_size_value.SetValueType (Value::eValueTypeScalar);
- page_to_free_size_value.SetClangType (clang_uint64_type);
+ page_to_free_size_value.SetCompilerType (clang_uint64_type);
Mutex::Locker locker(m_get_thread_item_info_retbuffer_mutex);