7940069905bee0b2e5f0661bf37c9f906ddf8603 |
|
10-Jul-2013 |
Greg Clayton <gclayton@apple.com> |
Cleanup on the unified section list changes. Main changes are: - ObjectFile::GetSymtab() and ObjectFile::ClearSymtab() no longer takes any flags - Module coordinates with the object files and contain a unified section list so that object file and symbol file can share sections when they need to, yet contain their own sections. Other cleanups: - Fixed Symbol::GetByteSize() to not have the symbol table compute the byte sizes on the fly - Modified the ObjectFileMachO class to compute symbol sizes all at once efficiently - Modified the Symtab class to store a file address lookup table for more efficient lookups - Removed Section::Finalize() and SectionList::Finalize() as they did nothing - Improved performance of the detection of symbol files that have debug maps by excluding stripped files and core files, debug files, object files and stubs - Added the ability to tell if an ObjectFile has been stripped with ObjectFile::IsStripped() (used this for the above performance improvement) git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@185990 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
a807ceef5dad2b24e5bae5c5a193ff03aa7ec8d9 |
|
01-Jul-2013 |
Michael Sartain <mikesart@valvesoftware.com> |
Split symbol support for ELF and Linux. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@185366 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
77e67a51acb825d79d25be687c085833713d5205 |
|
19-Jun-2013 |
Greg Clayton <gclayton@apple.com> |
Implemented a types.py module that allows types to be inspected for padding. The script was able to point out and save 40 bytes in each lldb_private::Section by being very careful where we need to have virtual destructors and also by re-ordering members. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@184364 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
102b2c2681c9a830afe25bfea35557421905e42c |
|
19-Apr-2013 |
Greg Clayton <gclayton@apple.com> |
After discussing with Chris Lattner, we require C++11, so lets get rid of the macros and just use C++11. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@179805 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
adf9e3db9be8f32e7eda7d4bb5b3b8f4d59ce46d |
|
10-Apr-2013 |
Jason Molenda <jmolenda@apple.com> |
When ObjectFileMachO::ParseSections() notices that it has a truncated file, zero out the SectionList so we don't try to do anything with this file. Currently we end up crashing later in the debug session when we read past the end of the file -- this at least gets us closer with something like ProcessMachCore printing "error: core file has no sections". <rdar://problem/13468295> git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@179152 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
464a5063bc59755cb6ec063d0b2491097302d2ab |
|
04-Mar-2013 |
Greg Clayton <gclayton@apple.com> |
<rdar://problem/13338643> DWARF with .o files now uses 40-60% less memory! Big fixes include: - Change line table internal representation to contain "file addresses". Since each line table is owned by a compile unit that is owned by a module, it makes address translation into lldb_private::Address easy to do when needed. - Removed linked address members/methods from lldb_private::Section and lldb_private::Address - lldb_private::LineTable can now relink itself using a FileRangeMap to make it easier to re-link line tables in the future - Added ObjectFile::ClearSymtab() so that we can get rid of the object file symbol tables after we parse them once since they are not needed and kept memory allocated for no reason - Moved the m_sections_ap (std::auto_ptr to section list) and m_symtab_ap (std::auto_ptr to the lldb_private::Symtab) out of each of the ObjectFile subclasses and put it into lldb_private::ObjectFile. - Changed how the debug map is parsed and stored to be able to: - Lazily parse the debug map for each object file - not require the address map for a .o file until debug information is linked for a .o file git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@176454 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
36da2aa6dc5ad9994b638ed09eb81c44cc05540b |
|
25-Jan-2013 |
Greg Clayton <gclayton@apple.com> |
<rdar://problem/13069948> Major fixed to allow reading files that are over 4GB. The main problems were that the DataExtractor was using 32 bit offsets as a data cursor, and since we mmap all of our object files we could run into cases where if we had a very large core file that was over 4GB, we were running into the 4GB boundary. So I defined a new "lldb::offset_t" which should be used for all file offsets. After making this change, I enabled warnings for data loss and for enexpected implicit conversions temporarily and found a ton of things that I fixed. Any functions that take an index internally, should use "size_t" for any indexes and also should return "size_t" for any sizes of collections. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@173463 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
716a6647382d32ea9859027f7eea07e6ff2acf76 |
|
08-Jun-2012 |
Sean Callanan <scallanan@apple.com> |
Committed a change to the SectionList that introduces a cache of address ranges for child sections, accelerating lookups. This cache is built during object file loading, and is then set in stone once the object files are done loading. (In Debug builds, we ensure that the cache is never invalidated after that.) git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@158188 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
9ab696e40530fa966e08cab7af77ea62e4fff1c0 |
|
27-Mar-2012 |
Greg Clayton <gclayton@apple.com> |
lldb_private::Section objects have a boolean flag that can be set that indicates that the section is thread specific. Any functions the load a module given a slide, will currently ignore any sections that are thread specific. lldb_private::Section now has: bool Section::IsThreadSpecific () const { return m_thread_specific; } void Section::SetIsThreadSpecific (bool b) { m_thread_specific = b; } The ELF plug-in has been modified to set this for the ".tdata" and the ".tbss" sections. Eventually we need to have each lldb_private::Thread subclass be able to resolve a thread specific section, but for now they will just not resolve. The code for that should be trivual to add, but the address resolving functions will need to be changed to take a "ExecutionContext" object instead of just a target so that thread specific sections can be resolved. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@153537 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
598df88bd6fc33c6fb330bc859bdc277795501f3 |
|
14-Mar-2012 |
Greg Clayton <gclayton@apple.com> |
<rdar://problem/10434005> Prepare LLDB to be built with C++11 by hiding all accesses to std::tr1 behind macros that allows us to easily compile for either C++. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@152698 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
3508c387c3f0c9ecc439d98048fd7694d41bab1b |
|
24-Feb-2012 |
Greg Clayton <gclayton@apple.com> |
<rdar://problem/10103468> 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. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@151336 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
b5a8f1498e1ddaeed5187a878d57ea0b74af9c26 |
|
05-Feb-2012 |
Greg Clayton <gclayton@apple.com> |
<rdar://problem/10560053> Fixed "target modules list" (aliased to "image list") to output more information by default. Modified the "target modules list" to have a few new options: "--header" or "-h" => show the image header address "--offset" or "-o" => show the image header address offset from the address in the file (the slide applied to the shared library) Removed the "--symfile-basename" or "-S" option, and repurposed it to "--symfile-unique" "-S" which will show the symbol file if it differs from the executable file. ObjectFile's can now be loaded from memory for cases where we don't have the files cached locally in an SDK or net mounted root. ObjectFileMachO can now read mach files from memory. Moved the section data reading code into the ObjectFile so that the object file can get the section data from Process memory if the file is only in memory. lldb_private::Module can now load its object file in a target with a rigid slide (very common operation for most dynamic linkers) by using: bool Module::SetLoadAddress (Target &target, lldb::addr_t offset, bool &changed) lldb::SBModule() now has a new constructor in the public interface: SBModule::SBModule (lldb::SBProcess &process, lldb::addr_t header_addr); This will find an appropriate ObjectFile plug-in to load an image from memory where the object file header is at "header_addr". git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@149804 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
db2dc2b824b61ef7578dc8cdad7b338aa82b1f17 |
|
12-Jan-2012 |
Greg Clayton <gclayton@apple.com> |
Big change in the way ObjectFile file contents are managed. We now mmap() the entire object file contents into memory with MAP_PRIVATE. We do this because object file contents can change on us and currently this helps alleviate this situation. It also make the code for accessing object file data much easier to manage and we don't end up opening the file, reading some data and closing the file over and over. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@148017 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
b0e68d996b28cf81a28aeceefd69f7ed8d4aba99 |
|
31-Mar-2011 |
Greg Clayton <gclayton@apple.com> |
Added some functions to our API related to classifying symbols as code, data, const data, etc, and also for SBAddress objects to classify their type of section they are in and also getting the module for a section offset address. lldb::SymbolType SBSymbol::GetType(); lldb::SectionType SBAddress::GetSectionType (); lldb::SBModule SBAddress::GetModule (); git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@128602 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
b344843f75ef893762c93fd0a22d2d45712ce74d |
|
24-Mar-2011 |
Greg Clayton <gclayton@apple.com> |
Fixed the LLDB build so that we can have private types, private enums and public types and public enums. This was done to keep the SWIG stuff from parsing all sorts of enums and types that weren't needed, and allows us to abstract our API better. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@128239 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
68ca823ad1ab94805bcee03f3ad0b649d94e5a09 |
|
25-Jan-2011 |
Greg Clayton <gclayton@apple.com> |
Fixed ProcessGDBRemote to kill the process correctly when it is either running or stopped. Added support for sections to be able to state if they are encrypted or not. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@124171 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
58e844b3561848e73e69d6d98746d4851e78306e |
|
08-Dec-2010 |
Greg Clayton <gclayton@apple.com> |
Added the ability to dump sections to a certain depth (for when sections have children sections). Modified SectionLoadList to do it's own multi-threaded protected on its map. The ThreadSafeSTLMap class was difficult to deal with and wasn't providing much utility, it was only getting in the way. Make sure when the communication read thread is about to exit, it clears the thread in the main class. Fixed the ModuleList to correctly ignore architectures and UUIDs if they aren't valid when searching for a matching module. If we specified a file with no arch, and then modified the file and loaded it again, it would not match on subsequent searches if the arch was invalid since it would compare an invalid architecture to the one that was found or selected within the shared library or executable. This was causing stale modules to stay around in the global module list when they should have been removed. Removed deprecated functions from the DynamicLoaderMacOSXDYLD class. Modified "ProcessGDBRemote::IsAlive" to check if we are connected to a gdb server and also make sure our process hasn't exited. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@121236 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
eea264007bc5fb42c8f3239726a9d28ae42e1b7b |
|
15-Sep-2010 |
Greg Clayton <gclayton@apple.com> |
Moved the section load list up into the target so we can use the target to symbolicate things without the need for a valid process subclass. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@113895 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
178710cd4307f3d44dc76ebd70fc7daf7ebe17c5 |
|
14-Sep-2010 |
Greg Clayton <gclayton@apple.com> |
Looking at some of the test suite failures in DWARF in .o files with the debug map showed that the location lists in the .o files needed some refactoring in order to work. The case that was failing was where a function that was in the "__TEXT.__textcoal_nt" in the .o file, and in the "__TEXT.__text" section in the main executable. This made symbol lookup fail due to the way we were finding a real address in the debug map which was by finding the section that the function was in in the .o file and trying to find this in the main executable. Now the section list supports finding a linked address in a section or any child sections. After fixing this, we ran into issue that were due to DWARF and how it represents locations lists. DWARF makes a list of address ranges and expressions that go along with those address ranges. The location addresses are expressed in terms of a compile unit address + offset. This works fine as long as nothing moves around. When stuff moves around and offsets change between the remapped compile unit base address and the new function address, then we can run into trouble. To deal with this, we now store supply a location list slide amount to any location list expressions that will allow us to make the location list addresses into zero based offsets from the object that owns the location list (always a function in our case). With these fixes we can now re-link random address ranges inside the debugger for use with our DWARF + debug map, incremental linking, and more. Another issue that arose when doing the DWARF in the .o files was that GCC 4.2 emits a ".debug_aranges" that only mentions functions that are externally visible. This makes .debug_aranges useless to us and we now generate a real address range lookup table in the DWARF parser at the same time as we index the name tables (that are needed because .debug_pubnames is just as useless). llvm-gcc doesn't generate a .debug_aranges section, though this could be fixed, we aren't going to rely upon it. Renamed a bunch of "UINT_MAX" to "UINT32_MAX". git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@113829 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
32a8c7e02b84fbc36ee0fdb553002a1880c8d83e |
|
22-Jul-2010 |
Greg Clayton <gclayton@apple.com> |
Modified both the ObjectFileMachO and ObjectFileELF to correctly set the SectionType for Section objects for DWARF. Modified the DWARF plug-in to get the DWARF sections by SectionType so we can safely abstract the LLDB core from section names for the various object file formats. Modified the SectionType definitions for .debug_pubnames and .debug_pubtypes to use the correct case. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@109054 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
15be8eddf3a2f9aff328197822ad8f338f96232b |
|
21-Jul-2010 |
Greg Clayton <gclayton@apple.com> |
Allow searching for a section by SectionType. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@109040 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
704363531ee4877ccc6d35d0702876096f54c67b |
|
01-Jul-2010 |
Greg Clayton <gclayton@apple.com> |
Centralized all disassembly into static functions in source/Core/Disassembler.cpp. Added the ability to read memory from the target's object files when we aren't running, so disassembling works before you run! Cleaned up the API to lldb_private::Target::ReadMemory(). Cleaned up the API to the Disassembler to use actual "lldb_private::Address" objects instead of just an "addr_t". This is nice because the Address objects when resolved carry along their section and module which can get us the object file. This allows Target::ReadMemory to be used when we are not running. Added a new lldb_private::Address dump style: DumpStyleDetailedSymbolContext This will show a full breakdown of what an address points to. To see some sample output, execute a "image lookup --address <addr>". Fixed SymbolContext::DumpStopContext(...) to not require a live process in order to be able to print function and symbol offsets. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@107350 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
661825b68e95abdfab2c7242c0d515e8260d1431 |
|
29-Jun-2010 |
Greg Clayton <gclayton@apple.com> |
Fixed debug map in executable + DWARF in .o debugging on Mac OS X. Added the ability to dump any file in the global module cache using any of the "image dump" commands. This allows us to dump the .o files that are used with DWARF + .o since they don't belong the the target list for the current target. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@107100 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
9dd6edde116d93777dae51ec550dee741019487e |
|
09-Jun-2010 |
Eli Friedman <eli.friedman@gmail.com> |
More warning/error fixes. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@105714 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|
24943d2ee8bfaa7cf5893e4709143924157a5c1e |
|
08-Jun-2010 |
Chris Lattner <sabre@nondot.org> |
Initial checkin of lldb code from internal Apple repo. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@105619 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/include/lldb/Core/Section.h
|