- May 08, 2012
-
-
rdar://problem/11358639Greg Clayton authored
Switch over to the "*-apple-macosx" for desktop and "*-apple-ios" for iOS triples. Also make the selection process for auto selecting platforms based off of an arch much better. llvm-svn: 156354
-
- May 01, 2012
-
-
Jim Ingham authored
Use a cache of the results of "GetFileAddress" from a symbol in the Comparator we are using to sort the various lookup indices by symbol address. When we switched to weak pointers, this lookup got slightly slower. Not enough to matter for most uses, but in the sort algorithm it does matter. llvm-svn: 155873
-
- Apr 26, 2012
-
-
Greg Clayton authored
Save more memory by not parsing the symbol table for stand alone DWARF files. We currently have SymbolFile plug-ins which all get the chance to say what they can parse in a symbol file. Prior to this fix we would ask the SymbolFileDWARF plug-in what abilities it had, and it would answer with "everything", and then we would check the SymbolFileSymtab plug-in what abilities it had, in case it had more abilities. The checking that SymbolFileSymtab does is a bit expensive as it pulls in the entire symbol table just to see if it can offer a few scraps of debug information. This causes all stand along DWARF files to pull in their symbol tables even though those symbols will never be used. This fix will check all SymbolFile plug-ins for their abilities and if any plug-in responds with "everything", then we stop the search. llvm-svn: 155638
-
rdar://problem/11271074Greg Clayton authored
<rdar://problem/11285931> Use the DWARRF end prologue markers when trying to skip prologue instructions instead of blindly using the second line table address entry. llvm-svn: 155600
-
- Apr 25, 2012
-
-
Jim Ingham authored
Make sure the end of the first line is still within the function, and if not, don't push the prologue past it. rdar://problem/11271074 llvm-svn: 155579
-
- Apr 24, 2012
-
-
Jim Ingham authored
llvm-svn: 155407
-
- Apr 18, 2012
-
-
Sean Callanan authored
Objective-C methods, and Objective-C properties. llvm-svn: 154972
-
Sean Callanan authored
for the original Decl, for debugging purposes. llvm-svn: 154957
-
- Apr 13, 2012
-
-
Sean Callanan authored
the debug information individual Decls came from. We've had a metadata infrastructure for a while, which was intended to solve a problem we've since dealt with in a different way. (It was meant to keep track of which definition of an Objective-C class was the "true" definition, but we now find it by searching the symbols for the class symbol.) The metadata is attached to the ExternalASTSource, which means it has a one-to-one correspondence with AST contexts. I've repurposed the metadata infrastructure to hold the object file and DIE offset for the DWARF information corresponding to a Decl. There are methods in ClangASTContext that get and set this metadata, and the ClangASTImporter is capable of tracking down the metadata for Decls that have been copied out of the debug information into the parser's AST context without using any additional memory. To see the metadata, you just have to enable the expression log: - (lldb) log enable lldb expr - and watch the import messages. The high 32 bits of the metadata indicate the index of the object file in its containing DWARFDebugMap; I have also added a log which you can use to track that mapping: - (lldb) log enable dwarf map - This adds 64 bits per Decl, which in my testing hasn't turned out to be very much (debugging Clang produces around 6500 Decls in my tests). To track how much data is being consumed, I've also added a global variable g_TotalSizeOfMetadata which tracks the total number of Decls that have metadata in all active AST contexts. Right now this metadata is enormously useful for tracking down bugs in the debug info parser. In the future I also want to use this information to provide more intelligent error messages instead of printing empty source lines wherever Clang refers to the location where something is defined. llvm-svn: 154634
-
- Apr 11, 2012
-
-
Greg Clayton authored
llvm-svn: 154503
-
- Apr 10, 2012
-
-
Greg Clayton authored
Added a packet history object to the GDBRemoteCommunication class that is always remembering the last 512 packets that were sent/received. These packets get dumped if logging gets enabled, or when the new expr lldb::DumpProcessGDBRemotePacketHistory (void *process, const char *log_file_path) global function is called. llvm-svn: 154354
-
- Apr 06, 2012
-
-
Greg Clayton authored
Check if the two clang opaque type pointers are equal before doing anything more exhaustive comparison. llvm-svn: 154181
-
- Apr 05, 2012
-
-
Sean Callanan authored
correctly if the setter/getter were not present in the debug information. The fixes are as follows: - We not only look for the method by its full name, but also look for automatically-generated methods when searching for a selector in an Objective-C interface. This is necessary to find accessors. - Extract the getter and setter name from the DW_TAG_APPLE_Property declaration in the DWARF if they are present; generate them if not. llvm-svn: 154067
-
- Apr 03, 2012
-
-
Bill Wendling authored
llvm-svn: 153944
-
Bill Wendling authored
llvm-svn: 153942
-
Sean Callanan authored
wchar_t as distinct from int. llvm-svn: 153920
-
rdar://problem/11160171Greg Clayton authored
Fixed an issue where there were more than one way to get a CompileUnitSP created when using SymbolFileDWARF with SymbolFileDWARFDebugMap. This led to an assertion that would fire under certain conditions. Now there is only one way to create the compile unit and it will "do the right thing". llvm-svn: 153908
-
- Mar 31, 2012
-
-
Greg Clayton authored
llvm-svn: 153786
-
- Mar 30, 2012
-
-
rdar://problem/11082392Greg Clayton authored
Fixed an issue that could cause circular type parsing that will assert and kill LLDB. Prior to this fix the DWARF parser would always create class types and not start their definitions (for both C++ and ObjC classes) until we were asked to complete the class later. When we had cases like: class A { class B { }; }; We would alway try to complete A before specifying "A" as the decl context for B. Turns out we can just start the definition and still not complete the class since we can check the TagDecl::isCompleteDefinition() function. This only works for C++ types. This means we will not be pulling in the full definition of parent classes all the time and should help with our memory consumption and also reduce the amount of debug info we have to parse. I also reduced redundant code that was checking in a lldb::clang_type_t was a possible C++ dynamic type since it was still completing the type, just to see if it was dynamic. This was fixed in another function that was checking for a type being dynamic as an ObjC or a C++ type, but there was dedicated fucntion for C++ that we missed. llvm-svn: 153713
-
- Mar 29, 2012
-
-
rdar://problem/11149427Greg Clayton authored
Line tables when using DWARF in .o files can be wrong when two entries get moved around by the compiler. This was due to incorrect logic in the line entry comparison operator. llvm-svn: 153685
-
Sean Callanan authored
for unbacked properties. We support two variants: one in which the getter/setter are provided by selector ("mySetter:") and one in which the getter/setter are provided by signature ("-[MyClass mySetter:]"). llvm-svn: 153675
-
- Mar 27, 2012
-
-
Greg Clayton authored
1 - sections only get a valid VM size if they have SHF_ALLOC in the section flags 2 - symbol names are marked as mangled if they start with "_Z" Also fixed the DWARF parser to correctly use the section file size when extracting the DWARF. llvm-svn: 153496
-
rdar://problem/11113279Greg Clayton authored
Fixed type lookups to "do the right thing". Prior to this fix, looking up a type using "foo::bar" would result in a type list that contains all types that had "bar" as a basename unless the symbol file was able to match fully qualified names (which our DWARF parser does not). This fix will allow type matches to be made based on the basename and then have the types that don't match filtered out. Types by name can be fully qualified, or partially qualified with the new "bool exact_match" parameter to the Module::FindTypes() method. This fixes some issue that we discovered with dynamic type resolution as well as improves the overall type lookups in LLDB. llvm-svn: 153482
-
- Mar 24, 2012
-
-
Enrico Granata authored
Adding a new API call IsTypeComplete() to SBType. This call is meant to check if the type has been previously completed or not (which is mostly interesting from a performance point of view) Adding a test case that checks that we do not complete types before due time. This should help us track cases similar to the cascading data formatters. llvm-svn: 153363
-
- Mar 22, 2012
-
-
rdar://problem/11095005Greg Clayton authored
Fixed a performance regression when dynamic types are enable where we would ask a C++ type if it can possibly be dynamic. Previously we would force the type to complete itself and then anwwer the question definitively. Now we ask the type if it is already complete and only definitively answer the question for completed types and just say "yes" for non-complete C++ types. We also always now answer yes for Objective C classes and do not complete those types either. llvm-svn: 153284
-
- Mar 20, 2012
-
-
rdar://problem/11078937Greg Clayton authored
LLDB can match incorrect line table entries when an address is between two valid line entries (in the gap between the valid debug info), now it doesn't! llvm-svn: 153077
-
- Mar 14, 2012
-
-
rdar://problem/11034170Greg Clayton authored
Simplify the locking strategy for Module and its owned objects to always use the Module's mutex to avoid A/B deadlocks. We had a case where a symbol vendor was locking itself and then calling a function that would try to get it's Module's mutex and at the same time another thread had the Module mutex that was trying to get the SymbolVendor mutex. Now any classes that inherit from ModuleChild should use the module lock using code like: void ModuleChildSubclass::Function { ModuleSP module_sp(GetModule()); if (module_sp) { lldb_private::Mutex::Locker locker(module_sp->GetMutex()); ... do work here... } } This will help avoid deadlocks by using as few locks as possible for a module and all its child objects and also enforce detecting if a module has gone away (the ModuleSP will be returned empty if the weak_ptr does refer to a valid object anymore). llvm-svn: 152679
-
- Mar 10, 2012
-
-
Sean Callanan authored
llvm-svn: 152472
-
Sean Callanan authored
llvm-svn: 152471
-
- Mar 08, 2012
-
-
Greg Clayton authored
llvm-svn: 152265
-
- Mar 07, 2012
-
-
rdar://problem/10997402Greg Clayton authored
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
-
Johnny Chen authored
expression command doesn't handle xmm or stmm registers... o Update ClangASTContext::GetBuiltinTypeForEncodingAndBitSize() to now handle eEncodingVector. o Modify RegisterValue::SetFromMemoryData() to fix the subtle error due to unitialized variables. o Add a test file for "expr $xmm0". llvm-svn: 152190
-
- Mar 06, 2012
-
-
Greg Clayton authored
This was done in SBTarget: lldb::SBInstructionList lldb::SBTarget::ReadInstructions (lldb::SBAddress base_addr, uint32_t count); Also cleaned up a few files in the LLDB.framework settings. llvm-svn: 152152
-
Enrico Granata authored
Fixing a crasher bug where we were not checking for NULL before trying to retrieve the format for a type llvm-svn: 152087
-
- Mar 02, 2012
-
-
Greg Clayton authored
llvm-svn: 151878
-
Sean Callanan authored
so that the expression parser can look up members of anonymous structs correctly. This meant creating all the proper IndirectFieldDecls in each Record after it has been completely populated with members. llvm-svn: 151868
-
- Mar 01, 2012
-
-
Sean Callanan authored
allocations by section. We install these sections in the target process and inform the JIT of their new locations. Also removed some unused variable warnings. llvm-svn: 151789
-
- Feb 26, 2012
-
-
Greg Clayton authored
more of the local path, platform path, associated symbol file, UUID, arch, object name and object offset. This allows many of the calls that were GetSharedModule to reduce the number of arguments that were used in a call to these functions. It also allows a module to be created with a ModuleSpec which allows many things to be specified prior to any accessors being called on the Module class itself. I was running into problems when adding support for "target symbol add" where you can specify a stand alone debug info file after debugging has started where I needed to specify the associated symbol file path and if I waited until after construction, the wrong symbol file had already been located. By using the ModuleSpec it allows us to construct a module with as little or as much information as needed and not have to change the parameter list. llvm-svn: 151476
-
- Feb 24, 2012
-
-
rdar://problem/10103468Greg Clayton authored
I started work on being able to add symbol files after a debug session had started with a new "target symfile add" command and quickly ran into problems with stale Address objects in breakpoint locations that had lldb_private::Section pointers into modules that had been removed or replaced. This also let to grabbing stale modules from those sections. So I needed to thread harded the Address, Section and related objects. To do this I modified the ModuleChild class to now require a ModuleSP on initialization so that a weak reference can created. I also changed all places that were handing out "Section *" to have them hand out SectionSP. All ObjectFile, SymbolFile and SymbolVendors were inheriting from ModuleChild so all of the find plug-in, static creation function and constructors now require ModuleSP references instead of Module *. Address objects now have weak references to their sections which can safely go stale when a module gets destructed. This checkin doesn't complete the "target symfile add" command, but it does get us a lot clioser to being able to do such things without a high risk of crashing or memory corruption. llvm-svn: 151336
-
- Feb 23, 2012
-
-
Sean Callanan authored
Objective-C classes. This allows LLDB to find ivars declared in class extensions in modules other than where the debugger is currently stopped (we already supported this when the debugger was stopped in the same module as the definition). This involved the following main changes: - The ObjCLanguageRuntime now knows how to hunt for the authoritative version of an Objective-C type. It looks for the symbol indicating a definition, and then gets the type from the module containing that symbol. - ValueObjects now report their type with a potential override, and the override is set if the type of the ValueObject is an Objective-C class or pointer type that is defined somewhere other than the original reported type. This means that "frame variable" will always use the complete type if one is available. - The ClangASTSource now looks for the complete type when looking for ivars. This means that "expr" will always use the complete type if one is available. - I added a testcase that verifies that both "frame variable" and "expr" work. llvm-svn: 151214
-