summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lldb/include/lldb/Symbol/Declaration.h2
-rw-r--r--lldb/include/lldb/Symbol/Function.h4
-rw-r--r--lldb/lldb.xcodeproj/project.pbxproj1
-rw-r--r--lldb/source/Commands/CommandObjectDisassemble.cpp2
-rw-r--r--lldb/source/Core/Disassembler.cpp13
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp4
-rw-r--r--lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp31
-rw-r--r--lldb/source/Symbol/Block.cpp10
-rw-r--r--lldb/source/Symbol/Declaration.cpp8
-rw-r--r--lldb/source/Symbol/Function.cpp8
-rw-r--r--lldb/source/Symbol/Type.cpp13
-rw-r--r--lldb/source/Symbol/Variable.cpp3
12 files changed, 72 insertions, 27 deletions
diff --git a/lldb/include/lldb/Symbol/Declaration.h b/lldb/include/lldb/Symbol/Declaration.h
index 2cc61b0e077..d23b48aaf07 100644
--- a/lldb/include/lldb/Symbol/Declaration.h
+++ b/lldb/include/lldb/Symbol/Declaration.h
@@ -100,7 +100,7 @@ public:
/// The stream to which to dump the object descripton.
//------------------------------------------------------------------
void
- Dump (Stream *s) const;
+ Dump (Stream *s, bool show_fullpaths) const;
void
DumpStopContext (Stream *s, bool show_fullpaths) const;
diff --git a/lldb/include/lldb/Symbol/Function.h b/lldb/include/lldb/Symbol/Function.h
index d5d8a3e4dce..2649f50be97 100644
--- a/lldb/include/lldb/Symbol/Function.h
+++ b/lldb/include/lldb/Symbol/Function.h
@@ -96,7 +96,7 @@ public:
/// The stream to which to dump the object descripton.
//------------------------------------------------------------------
void
- Dump (Stream *s) const;
+ Dump (Stream *s, bool show_fullpaths) const;
//------------------------------------------------------------------
/// Get accessor for the declaration information.
@@ -236,7 +236,7 @@ public:
/// The stream to which to dump the object descripton.
//------------------------------------------------------------------
void
- Dump(Stream *s) const;
+ Dump(Stream *s, bool show_fullpaths) const;
void
DumpStopContext (Stream *s) const;
diff --git a/lldb/lldb.xcodeproj/project.pbxproj b/lldb/lldb.xcodeproj/project.pbxproj
index 2331f84bc99..afb2ed60d9d 100644
--- a/lldb/lldb.xcodeproj/project.pbxproj
+++ b/lldb/lldb.xcodeproj/project.pbxproj
@@ -2339,7 +2339,6 @@
isa = PBXProject;
buildConfigurationList = 1DEB91EF08733DB70010E9CD /* Build configuration list for PBXProject "lldb" */;
compatibilityVersion = "Xcode 3.1";
- developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
en,
diff --git a/lldb/source/Commands/CommandObjectDisassemble.cpp b/lldb/source/Commands/CommandObjectDisassemble.cpp
index 49a56774e24..a5fc7f6cfab 100644
--- a/lldb/source/Commands/CommandObjectDisassemble.cpp
+++ b/lldb/source/Commands/CommandObjectDisassemble.cpp
@@ -196,7 +196,7 @@ CommandObjectDisassemble::Execute
ExecutionContext exe_ctx(interpreter.GetDebugger().GetExecutionContext());
if (m_options.show_mixed && m_options.num_lines_context == 0)
- m_options.num_lines_context = 3;
+ m_options.num_lines_context = 1;
if (!m_options.m_func_name.empty())
{
diff --git a/lldb/source/Core/Disassembler.cpp b/lldb/source/Core/Disassembler.cpp
index 40d8d300682..c2d36ef5b16 100644
--- a/lldb/source/Core/Disassembler.cpp
+++ b/lldb/source/Core/Disassembler.cpp
@@ -107,7 +107,10 @@ Disassembler::Disassemble
if (module)
{
if (!module->FindFunctions (name,
- eFunctionNameTypeBase | eFunctionNameTypeFull | eFunctionNameTypeMethod | eFunctionNameTypeSelector,
+ eFunctionNameTypeBase |
+ eFunctionNameTypeFull |
+ eFunctionNameTypeMethod |
+ eFunctionNameTypeSelector,
true,
sc_list))
return false;
@@ -115,7 +118,10 @@ Disassembler::Disassemble
else
{
if (exe_ctx.target->GetImages().FindFunctions (name,
- eFunctionNameTypeBase | eFunctionNameTypeFull | eFunctionNameTypeMethod | eFunctionNameTypeSelector,
+ eFunctionNameTypeBase |
+ eFunctionNameTypeFull |
+ eFunctionNameTypeMethod |
+ eFunctionNameTypeSelector,
false,
sc_list))
{
@@ -240,7 +246,8 @@ Disassembler::Disassemble
if (offset != 0)
strm.EOL();
- sc.DumpStopContext(&strm, process, addr, true, true, false);
+ sc.DumpStopContext(&strm, process, addr, false, true, false);
+ strm.EOL();
if (sc.comp_unit && sc.line_entry.IsValid())
{
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
index bcae13c3404..d388d543503 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
@@ -1834,6 +1834,10 @@ SymbolFileDWARF::FindTypes(const SymbolContext& sc, const ConstString &name, boo
if (!append)
types.Clear();
+ // Index if we already haven't to make sure the compile units
+ // get indexed and make their global DIE index list
+ if (!m_indexed)
+ Index ();
const uint32_t initial_types_size = types.GetSize();
DWARFCompileUnit* cu = NULL;
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
index b99a30ce476..d216ef538c5 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARFDebugMap.cpp
@@ -878,14 +878,35 @@ SymbolFileDWARFDebugMap::FindFunctions (const RegularExpression& regex, bool app
uint32_t
-SymbolFileDWARFDebugMap::FindTypes (const SymbolContext& sc, const ConstString &name, bool append, uint32_t max_matches, TypeList& types)
+SymbolFileDWARFDebugMap::FindTypes
+(
+ const SymbolContext& sc,
+ const ConstString &name,
+ bool append,
+ uint32_t max_matches,
+ TypeList& types
+)
{
- SymbolFileDWARF *oso_dwarf = GetSymbolFile (sc);
- if (oso_dwarf)
- return oso_dwarf->FindTypes (sc, name, append, max_matches, types);
if (!append)
types.Clear();
- return 0;
+
+ const uint32_t initial_types_size = types.GetSize();
+ SymbolFileDWARF *oso_dwarf;
+
+ if (sc.comp_unit)
+ {
+ oso_dwarf = GetSymbolFile (sc);
+ if (oso_dwarf)
+ return oso_dwarf->FindTypes (sc, name, append, max_matches, types);
+ }
+ else
+ {
+ uint32_t oso_idx = 0;
+ while ((oso_dwarf = GetSymbolFileByOSOIndex (oso_idx++)) != NULL)
+ oso_dwarf->FindTypes (sc, name, append, max_matches, types);
+ }
+
+ return types.GetSize() - initial_types_size;
}
//
diff --git a/lldb/source/Symbol/Block.cpp b/lldb/source/Symbol/Block.cpp
index 0096c5312dc..a2193891cf7 100644
--- a/lldb/source/Symbol/Block.cpp
+++ b/lldb/source/Symbol/Block.cpp
@@ -57,7 +57,10 @@ Block::GetDescription(Stream *s, Function *function, lldb::DescriptionLevel leve
}
if (m_inlineInfoSP.get() != NULL)
- m_inlineInfoSP->Dump(s);
+ {
+ bool show_fullpaths = (level == eDescriptionLevelVerbose);
+ m_inlineInfoSP->Dump(s, show_fullpaths);
+ }
}
void
@@ -83,7 +86,10 @@ Block::Dump(Stream *s, addr_t base_addr, int32_t depth, bool show_context) const
s->Printf(", parent = {0x%8.8x}", parent_block->GetID());
}
if (m_inlineInfoSP.get() != NULL)
- m_inlineInfoSP->Dump(s);
+ {
+ bool show_fullpaths = false;
+ m_inlineInfoSP->Dump(s, show_fullpaths);
+ }
if (!m_ranges.empty())
{
diff --git a/lldb/source/Symbol/Declaration.cpp b/lldb/source/Symbol/Declaration.cpp
index 2f312d461c4..8685d8df7cc 100644
--- a/lldb/source/Symbol/Declaration.cpp
+++ b/lldb/source/Symbol/Declaration.cpp
@@ -57,11 +57,15 @@ Declaration::Clear()
}
void
-Declaration::Dump(Stream *s) const
+Declaration::Dump(Stream *s, bool show_fullpaths) const
{
if (m_file)
{
- *s << ", decl = " << m_file;
+ *s << ", decl = ";
+ if (show_fullpaths)
+ *s << m_file;
+ else
+ *s << m_file.GetFilename();
if (m_line > 0)
s->Printf(":%u", m_line);
if (m_column > 0)
diff --git a/lldb/source/Symbol/Function.cpp b/lldb/source/Symbol/Function.cpp
index 8989f2e354d..3c108d7e2b4 100644
--- a/lldb/source/Symbol/Function.cpp
+++ b/lldb/source/Symbol/Function.cpp
@@ -45,11 +45,11 @@ FunctionInfo::~FunctionInfo()
}
void
-FunctionInfo::Dump(Stream *s) const
+FunctionInfo::Dump(Stream *s, bool show_fullpaths) const
{
if (m_name)
*s << ", name = \"" << m_name << "\"";
- m_declaration.Dump(s);
+ m_declaration.Dump(s, show_fullpaths);
}
@@ -131,9 +131,9 @@ InlineFunctionInfo::Compare(const InlineFunctionInfo& a, const InlineFunctionInf
}
void
-InlineFunctionInfo::Dump(Stream *s) const
+InlineFunctionInfo::Dump(Stream *s, bool show_fullpaths) const
{
- FunctionInfo::Dump(s);
+ FunctionInfo::Dump(s, show_fullpaths);
if (m_mangled)
m_mangled.Dump(s);
}
diff --git a/lldb/source/Symbol/Type.cpp b/lldb/source/Symbol/Type.cpp
index 886367f7ed1..4a5e4e1eba9 100644
--- a/lldb/source/Symbol/Type.cpp
+++ b/lldb/source/Symbol/Type.cpp
@@ -87,13 +87,15 @@ lldb_private::Type::GetDescription (Stream *s, lldb::DescriptionLevel level, boo
{
*s << "id = " << (const UserID&)*this;
- if (show_name && m_name)
+ // Call the name accessor to make sure we resolve the type name
+ if (show_name && GetName())
*s << ", name = \"" << m_name << '"';
- if (m_byte_size != 0)
+ // Call the get byte size accesor so we resolve our byte size
+ if (GetByteSize())
s->Printf(", byte-size = %zu", m_byte_size);
-
- m_decl.Dump(s);
+ bool show_fullpaths = (level == lldb::eDescriptionLevelVerbose);
+ m_decl.Dump(s, show_fullpaths);
if (m_clang_qual_type)
{
@@ -138,7 +140,8 @@ lldb_private::Type::Dump (Stream *s, bool show_context)
s->PutCString(" )");
}
- m_decl.Dump(s);
+ bool show_fullpaths = false;
+ m_decl.Dump (s,show_fullpaths);
if (m_clang_qual_type)
{
diff --git a/lldb/source/Symbol/Variable.cpp b/lldb/source/Symbol/Variable.cpp
index 27af65ff0be..7a4e12cad86 100644
--- a/lldb/source/Symbol/Variable.cpp
+++ b/lldb/source/Symbol/Variable.cpp
@@ -91,7 +91,8 @@ Variable::Dump(Stream *s, bool show_context) const
s->PutCString(" )");
}
- m_declaration.Dump(s);
+ bool show_fullpaths = false;
+ m_declaration.Dump(s, show_fullpaths);
if (m_location.IsValid())
{
OpenPOWER on IntegriCloud