llvm-c166/lldb/source/Core
Jason Molenda fbcb7f2c4e The first part of an lldb native stack unwinder.
The Unwind and RegisterContext subclasses still need
to be finished; none of this code is used by lldb at
this point (unless you call into it by hand).

The ObjectFile class now has an UnwindTable object.

The UnwindTable object has a series of FuncUnwinders
objects (Function Unwinders) -- one for each function
in that ObjectFile we've backtraced through during this
debug session.

The FuncUnwinders object has a few different UnwindPlans.
UnwindPlans are a generic way of describing how to find
the canonical address of a given function's stack frame
(the CFA idea from DWARF/eh_frame) and how to restore the
caller frame's register values, if they have been saved
by this function.

UnwindPlans are created from different sources.  One source is the
eh_frame exception handling information generated by the compiler
for unwinding an exception throw.  Another source is an assembly
language inspection class (UnwindAssemblyProfiler, uses the Plugin
architecture) which looks at the instructions in the funciton
prologue and describes the stack movements/register saves that are
done.

Two additional types of UnwindPlans that are worth noting are
the "fast" stack UnwindPlan which is useful for making a first
pass over a thread's stack, determining how many stack frames there
are and retrieving the pc and CFA values for each frame (enough
to create StackFrameIDs).  Only a minimal set of registers is
recovered during a fast stack walk.  

The final UnwindPlan is an architectural default unwind plan.
These are provided by the ArchDefaultUnwindPlan class (which uses
the plugin architecture).  When no symbol/function address range can
be found for a given pc value -- when we have no eh_frame information
and when we don't have a start address so we can't examine the assembly
language instrucitons -- we have to make a best guess about how to 
unwind.  That's when we use the architectural default UnwindPlan.
On x86_64, this would be to assume that rbp is used as a stack pointer
and we can use that to find the caller's frame pointer and pc value.
It's a last-ditch best guess about how to unwind out of a frame.

There are heuristics about when to use one UnwindPlan versues the other --
this will all happen in the still-begin-written UnwindLLDB subclass of
Unwind which runs the UnwindPlans.

llvm-svn: 113581
2010-09-10 07:49:16 +00:00
..
Address.cpp Cleaned up the output of "image lookup --address <ADDR>" which involved 2010-09-10 01:30:46 +00:00
AddressRange.cpp Cleaned up the output of "image lookup --address <ADDR>" which involved 2010-09-10 01:30:46 +00:00
AddressResolver.cpp
AddressResolverFileLine.cpp Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
AddressResolverName.cpp Added function name types to allow us to set breakpoints by name more 2010-06-28 21:30:43 +00:00
ArchSpec.cpp Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
Baton.cpp
Broadcaster.cpp
Communication.cpp Remove a premature invalidation of a threads pthread_t handle, thus avoiding 2010-07-23 15:43:25 +00:00
Connection.cpp
ConnectionFileDescriptor.cpp Warnings cleanup patch from Jean-Daniel Dupas. 2010-07-23 15:37:46 +00:00
ConstString.cpp Improved name demangling performance by 20% on darwin. 2010-09-03 23:26:12 +00:00
DataBufferHeap.cpp
DataBufferMemoryMap.cpp Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
DataExtractor.cpp Avoid std::bitset<64>::to_string() since it is missing in earlier C++ 2010-07-21 01:08:41 +00:00
Debugger.cpp Add comments to InstanceSettings constructors explaining why they have 2010-09-09 18:26:37 +00:00
Disassembler.cpp Fixed an error that could occur during disassembly that could cause a function name to be printed before the first _and_ the second instruction of disassembly when there are two symbols -- one debug symbol and one linker symbol. 2010-09-06 23:11:45 +00:00
DynamicLoader.cpp
Error.cpp Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
Event.cpp Remove use of STL collection class use of the "data()" method since it isn't 2010-07-20 22:52:08 +00:00
FileSpec.cpp If the file the user specifies can't be found in the current directory, 2010-09-10 04:48:55 +00:00
FileSpecList.cpp
Flags.cpp
InputReader.cpp I enabled some extra warnings for hidden local variables and for hidden 2010-07-14 00:18:15 +00:00
Language.cpp Created lldb::LanguageType by moving an enumeration from the 2010-07-28 02:04:09 +00:00
Listener.cpp
Log.cpp Fixed the log streams for logs that output to 2010-06-23 21:28:25 +00:00
Makefile Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
Mangled.cpp Improved name demangling performance by 20% on darwin. 2010-09-03 23:26:12 +00:00
Module.cpp Remove the Flags member in lldb_private::Module in favor of bitfield boolean 2010-09-07 23:40:05 +00:00
ModuleChild.cpp
ModuleList.cpp Got a lot of the kinks worked out in the inline support after debugging more 2010-08-24 21:05:24 +00:00
PluginManager.cpp The first part of an lldb native stack unwinder. 2010-09-10 07:49:16 +00:00
RegularExpression.cpp Remove use of STL collection class use of the "data()" method since it isn't 2010-07-20 22:52:08 +00:00
Scalar.cpp Move Args.{cpp,h} and Options.{cpp,h} to Interpreter where they really belong. 2010-06-15 19:49:27 +00:00
SearchFilter.cpp Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
Section.cpp Modified both the ObjectFileMachO and ObjectFileELF to correctly set the 2010-07-21 22:54:26 +00:00
SourceManager.cpp
State.cpp
Stream.cpp Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
StreamFile.cpp Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
StreamString.cpp
StringList.cpp Merged Eli Friedman's linux build changes where he added Makefile files that 2010-07-09 20:39:50 +00:00
Timer.cpp
TTYState.cpp
UserID.cpp Move trivial parts of UserID into the header. 2010-06-22 10:44:12 +00:00
UserSettingsController.cpp Make all debugger-level user settable variables into instance variables. 2010-09-09 06:25:08 +00:00
UUID.cpp Remove unused uuid_t constructor for lldb_private::UUID. 2010-06-10 03:08:05 +00:00
Value.cpp Changed "Error Value::GetValueAsData (...)" to set the data extractor byte 2010-08-18 18:28:52 +00:00
ValueObject.cpp StackFrame objects now own ValueObjects for any frame variables (locals, args, 2010-09-02 02:59:18 +00:00
ValueObjectChild.cpp Change over to using the definitions for mach-o types and defines to the 2010-07-21 22:12:05 +00:00
ValueObjectList.cpp StackFrame objects now own ValueObjects for any frame variables (locals, args, 2010-09-02 02:59:18 +00:00
ValueObjectRegister.cpp Change over to using the definitions for mach-o types and defines to the 2010-07-21 22:12:05 +00:00
ValueObjectVariable.cpp StackFrame objects now own ValueObjects for any frame variables (locals, args, 2010-09-02 02:59:18 +00:00
VMRange.cpp Added support for inlined stack frames being represented as real stack frames 2010-08-24 00:45:41 +00:00