summaryrefslogtreecommitdiffstats
path: root/lldb/source/Core/Address.cpp
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2012-03-07 21:03:09 +0000
committerGreg Clayton <gclayton@apple.com>2012-03-07 21:03:09 +0000
commite761213428bb1ad8a8835ac4bf52233ae2121f3c (patch)
tree746b13d7e3e796f69acc994362c23f732a380542 /lldb/source/Core/Address.cpp
parent377f1f2d399171983cc26c13e81bad1699025dde (diff)
downloadbcm5719-llvm-e761213428bb1ad8a8835ac4bf52233ae2121f3c.tar.gz
bcm5719-llvm-e761213428bb1ad8a8835ac4bf52233ae2121f3c.zip
<rdar://problem/10997402>
This fix really needed to happen as a previous fix I had submitted for calculating symbol sizes made many symbols appear to have zero size since the function that was calculating the symbol size was calling another function that would cause the calculation to happen again. This resulted in some symbols having zero size when they shouldn't. This could then cause infinite stack traces and many other side affects. llvm-svn: 152244
Diffstat (limited to 'lldb/source/Core/Address.cpp')
-rw-r--r--lldb/source/Core/Address.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lldb/source/Core/Address.cpp b/lldb/source/Core/Address.cpp
index 75eb742fdfe..005a1a03e80 100644
--- a/lldb/source/Core/Address.cpp
+++ b/lldb/source/Core/Address.cpp
@@ -468,7 +468,7 @@ Address::Dump (Stream *s, ExecutionContextScope *exe_scope, DumpStyle style, Dum
if (symbol_name)
{
s->PutCString(symbol_name);
- addr_t delta = file_Addr - symbol->GetAddressRangePtr()->GetBaseAddress().GetFileAddress();
+ addr_t delta = file_Addr - symbol->GetAddress().GetFileAddress();
if (delta)
s->Printf(" + %llu", delta);
showed_info = true;
@@ -632,9 +632,9 @@ Address::Dump (Stream *s, ExecutionContextScope *exe_scope, DumpStyle style, Dum
if (sc.function == NULL && sc.symbol != NULL)
{
// If we have just a symbol make sure it is in the right section
- if (sc.symbol->GetAddressRangePtr())
+ if (sc.symbol->ValueIsAddress())
{
- if (sc.symbol->GetAddressRangePtr()->GetBaseAddress().GetSection() != GetSection())
+ if (sc.symbol->GetAddress().GetSection() != GetSection())
{
// don't show the module if the symbol is a trampoline symbol
show_stop_context = false;
@@ -685,7 +685,7 @@ Address::Dump (Stream *s, ExecutionContextScope *exe_scope, DumpStyle style, Dum
// as our address. If it isn't, then we might have just found
// the last symbol that came before the address that we are
// looking up that has nothing to do with our address lookup.
- if (sc.symbol->GetAddressRangePtr() && sc.symbol->GetAddressRangePtr()->GetBaseAddress().GetSection() != GetSection())
+ if (sc.symbol->ValueIsAddress() && sc.symbol->GetAddress().GetSection() != GetSection())
sc.symbol = NULL;
}
sc.GetDescription(s, eDescriptionLevelBrief, target);
OpenPOWER on IntegriCloud