52f792329be5db8e38961350589e97e8f2823acd |
|
12-Jul-2013 |
Greg Clayton <gclayton@apple.com> |
Huge change to clean up types. A long time ago we start with clang types that were created by the symbol files and there were many functions in lldb_private::ClangASTContext that helped. Later we create ClangASTType which contains a clang::ASTContext and an opauque QualType, but we didn't switch over to fully using it. There were a lot of places where we would pass around a raw clang_type_t and also pass along a clang::ASTContext separately. This left room for error. This checkin change all type code over to use ClangASTType everywhere and I cleaned up the interfaces quite a bit. Any code that was in ClangASTContext that was type related, was moved over into ClangASTType. All code that used these types was switched over to use all of the new goodness. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@186130 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
0e191607adcb0ea8ebd06c278be648a7f5c0097f |
|
10-May-2013 |
Greg Clayton <gclayton@apple.com> |
<rdar://problem/13854277> <rdar://problem/13594769> Main changes in this patch include: - cleanup plug-in interface and use ConstStrings for plug-in names - Modfiied the BSD Archive plug-in to be able to pick out the correct .o file when .a files contain multiple .o files with the same name by using the timestamp - Modified SymbolFileDWARFDebugMap to properly verify the timestamp on .o files it loads to ensure we don't load updated .o files and cause problems when debugging The plug-in interface changes: Modified the lldb_private::PluginInterface class that all plug-ins inherit from: Changed: virtual const char * GetPluginName() = 0; To: virtual ConstString GetPluginName() = 0; Removed: virtual const char * GetShortPluginName() = 0; - Fixed up all plug-in to adhere to the new interface and to return lldb_private::ConstString values for the plug-in names. - Fixed all plug-ins to return simple names with no prefixes. Some plug-ins had prefixes and most ones didn't, so now they all don't have prefixed names, just simple names like "linux", "gdb-remote", etc. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@181631 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
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/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
28d0b698ab8b28c91c8311a01c950ff0e82957d0 |
|
19-Dec-2012 |
Greg Clayton <gclayton@apple.com> |
Don't read the SP when getting argument values from registers in case the SP isn't available. We don't want the availability of SP to limit when we get get arguments from registers. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@170476 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
37816a3429a075e19b74f64fd642d5a5d7ec6f2f |
|
26-Oct-2012 |
Jason Molenda <jmolenda@apple.com> |
Add a new capability to RegisterContextLLDB: To recognize when the Full UnwindPlan is trying to do an impossible unwind; in that case invalidate the Full UnwindPlan and replace it with the architecture default unwind plan. This is a scenario that happens occasionally with arm unwinds in particular; the instruction analysis based full unwindplan can mis-parse the functions and the stack walk stops prematurely. Now we can do a simpleminded frame-chain walk to find the caller frame and continue the unwind. It's not ideal but given the complicated nature of analyzing the arm functions, and the lack of eh_frame information on iOS, it is a distinct improvement and fixes some long-standing problems with the unwinder on that platform. This is fixing <rdar://problem/12091421>. I may re-use this invalidate feature in the future if I can identify other cases where the full unwindplan's unwind information is clearly incorrect. This checkin also includes some cleanup for the volatile register definition in the arm ABI plugin for <rdar://problem/10652166> although work remains to be done for that bug. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@166757 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
466574555e98bc093d443d88492ce9db6ef3015f |
|
27-Sep-2012 |
Jim Ingham <jingham@apple.com> |
Implement returning integer values in "thread return" for arm, x86_64 and i386. Also returns floats & doubles on x86_64. <rdar://problem/8356523> git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@164741 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
a17a81a1a9ff6b8d87c4a1e47dd874f6ea8a4f1d |
|
12-Sep-2012 |
Jim Ingham <jingham@apple.com> |
Start at getting "thread return" working. Doesn't work yet. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@163670 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
68fa4ec4361d1ea5a78a8a7eba2b8015e3dd68f7 |
|
14-Jul-2012 |
Jason Molenda <jmolenda@apple.com> |
Switch nearly all of the use of the UnwindPlan::Row's to go through a shared pointer to ease some memory management issues with a patch I'm working on. The main complication with using SPs for these objects is that most methods that build up an UnwindPlan will construct a Row to a given instruction point in a function, then add additional regsaves in the next instruction point to that row and push it again. A little care is needed to not mutate the previous instruction point's Row once these are switched to being held behing shared pointers. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@160214 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
8d789804a2b211c4c74073e245e023a6fc4a777c |
|
12-Jul-2012 |
Greg Clayton <gclayton@apple.com> |
Removed unused variable to quiet a warning. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@160086 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
7fad24a9fd7226016b28fef78930501a1bef898c |
|
09-Jul-2012 |
Jason Molenda <jmolenda@apple.com> |
Simplify the CreateDefaultUnwindPlan methods for the x86 and arm unwinders a bit -- we're creating the UnwindPlan here, we can set the register set to whatever is convenient for us, no need to handle different register sets. A handful of small comment fixes I noticed while reading through the code. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@159924 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
b170aee2daacc83e3d71c3e3acc9d56c89893a7b |
|
08-May-2012 |
Greg Clayton <gclayton@apple.com> |
<rdar://problem/11358639> 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. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@156354 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
402607fe513617c06282d4ae479522e244a53b71 |
|
29-Feb-2012 |
Johnny Chen <johnny.chen@apple.com> |
rdar://problem/10652076 Initial step -- infrastructure change -- to fix the bug. Change the RegisterInfo data structure to contain two additional fields (uint32_t *value_rges and uint32_t *invalidate_regs) to facilitate architectures which have register mapping. Update all existing RegsiterInfo arrays to have two extra NULL's (the additional fields) in each row, GDBRemoteRegisterContext.cpp is modified to add d0-d15 and q0-q15 register info entries which take advantage of the value_regs field to specify the containment relationship: d0 -> (s0, s1) ... d15 -> (s30, s31) q0 -> (d0, d1) ... q15 -> (d30, d31) git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@151686 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
f4124deeb9532044a38c0774ced872f2709347da |
|
21-Feb-2012 |
Greg Clayton <gclayton@apple.com> |
Thread hardening part 3. Now lldb_private::Thread objects have std::weak_ptr objects for the backlink to the lldb_private::Process. The issues we were running into before was someone was holding onto a shared pointer to a lldb_private::Thread for too long, and the lldb_private::Process parent object would get destroyed and the lldb_private::Thread had a "Process &m_process" member which would just treat whatever memory that used to be a Process as a valid Process. This was mostly happening for lldb_private::StackFrame objects that had a member like "Thread &m_thread". So this completes the internal strong/weak changes. Documented the ExecutionContext and ExecutionContextRef classes so that our LLDB developers can understand when and where to use ExecutionContext and ExecutionContextRef objects. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@151009 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
016ef8886cd429f8a53bff967e601f831e409eaa |
|
22-Dec-2011 |
Jim Ingham <jingham@apple.com> |
Improve the x86_64 return value decoder to handle most structure returns. Switch from GetReturnValue, which was hardly ever used, to GetReturnValueObject which is much more convenient. Return the "return value object" as a persistent variable if requested. git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@147157 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
819dd5e0990e8550d0185f65cc5cf4bc3d9d1058 |
|
15-Sep-2011 |
Jason Molenda <jmolenda@apple.com> |
Have the FuncUnwinder object request & provide an architecture-defined UnwindPlan for unwinding from the first instruction of an otherwise unknown function call (GetUnwindPlanArchitectureDefaultAtFunctionEntry()). Update RegisterContextLLDB::GetFullUnwindPlanForFrame() to detect the case of a frame 0 at address 0x0 which indicates that we jumped through a NULL function pointer. Use the ABI's FunctionEntryUnwindPlan to find the caller frame. These changes make it so lldb can identify the calling frame correctly in code like int main () { void (*f)(void) = 0; f(); } git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@139760 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
37f962e785be99dc4f0c5e9d02416992ff03bbd0 |
|
22-Aug-2011 |
Greg Clayton <gclayton@apple.com> |
Added a new plug-in type: lldb_private::OperatingSystem. The operating system plug-ins are add on plug-ins for the lldb_private::Process class that can add thread contexts that are read from memory. It is common in kernels to have a lot of threads that are not currently executing on any cores (JTAG debugging also follows this sort of thing) and are context switched out whose state is stored in memory data structures. Clients can now subclass the OperatingSystem plug-ins and then make sure their Create functions correcltly only enable themselves when the right binary/target triple are being debugged. The operating system plug-ins get a chance to attach themselves to processes just after launching or attaching and are given a lldb_private::Process object pointer which can be inspected to see if the main executable, target triple, or any shared libraries match a case where the OS plug-in should be used. Currently the OS plug-ins can create new threads, define the register contexts for these threads (which can all be different if desired), and populate and manage the thread info (stop reason, registers in the register context) as the debug session goes on. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@138228 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
6561155acc9dee660de73e4aa8215839a06f01a7 |
|
04-Jun-2011 |
Greg Clayton <gclayton@apple.com> |
Created a std::string in the base StopInfo class for the description and cleaned up all base classes that had their own copy. Added a SetDescription accessor to the StopInfo class. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@132615 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
c0fa53324d62a48257c092a3347d6e7236aa3152 |
|
23-May-2011 |
Greg Clayton <gclayton@apple.com> |
Added new lldb_private::Process memory read/write functions to stop a bunch of duplicated code from appearing all over LLDB: lldb::addr_t Process::ReadPointerFromMemory (lldb::addr_t vm_addr, Error &error); bool Process::WritePointerToMemory (lldb::addr_t vm_addr, lldb::addr_t ptr_value, Error &error); size_t Process::ReadScalarIntegerFromMemory (lldb::addr_t addr, uint32_t byte_size, bool is_signed, Scalar &scalar, Error &error); size_t Process::WriteScalarToMemory (lldb::addr_t vm_addr, const Scalar &scalar, uint32_t size, Error &error); in lldb_private::Process the following functions were renamed: From: uint64_t Process::ReadUnsignedInteger (lldb::addr_t load_addr, size_t byte_size, Error &error); To: uint64_t Process::ReadUnsignedIntegerFromMemory (lldb::addr_t load_addr, size_t byte_size, uint64_t fail_value, Error &error); Cleaned up a lot of code that was manually doing what the above functions do to use the functions listed above. Added the ability to get a scalar value as a buffer that can be written down to a process (byte swapping the Scalar value if needed): uint32_t Scalar::GetAsMemoryData (void *dst, uint32_t dst_len, lldb::ByteOrder dst_byte_order, Error &error) const; The "dst_len" can be smaller that the size of the scalar and the least significant bytes will be written. "dst_len" can also be larger and the most significant bytes will be padded with zeroes. Centralized the code that adds or removes address bits for callable and opcode addresses into lldb_private::Target: lldb::addr_t Target::GetCallableLoadAddress (lldb::addr_t load_addr, AddressClass addr_class) const; lldb::addr_t Target::GetOpcodeLoadAddress (lldb::addr_t load_addr, AddressClass addr_class) const; All necessary lldb_private::Address functions now use the target versions so changes should only need to happen in one place if anything needs updating. Fixed up a lot of places that were calling : addr_t Address::GetLoadAddress(Target*); to call the Address::GetCallableLoadAddress() or Address::GetOpcodeLoadAddress() as needed. There were many places in the breakpoint code where things could go wrong for ARM if these weren't used. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131878 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
5a26910ed231503d2a7a71365a44e379a994f4e6 |
|
22-May-2011 |
Greg Clayton <gclayton@apple.com> |
Added functions to lldb_private::Address to set an address from a load address and set the address as an opcode address or as a callable address. This is needed in various places in the thread plans to make sure that addresses that might be found in symbols or runtime might already have extra bits set (ARM/Thumb). The new functions are: bool Address::SetCallableLoadAddress (lldb::addr_t load_addr, Target *target); bool Address::SetOpcodeLoadAddress (lldb::addr_t load_addr, Target *target); SetCallableLoadAddress will initialize a section offset address if it can, and if so it might possibly set some bits in the address to make the address callable (bit zero might get set for ARM for Thumb functions). SetOpcodeLoadAddress will initialize a section offset address using the specified target and it will strip any special address bits if needed depending on the target. Fixed the ABIMacOSX_arm::GetArgumentValues() function to require arguments 1-4 to be in the needed registers (previously this would incorrectly fallback to the stack) and return false if unable to get the register values. The function was also modified to first look for the generic argument registers and then fall back to finding the registers by name. Fixed the objective trampoline handler to use the new Address::SetOpcodeLoadAddress function when needed to avoid address mismatches when trying to complete steps into objective C methods. Make similar fixes inside the AppleThreadPlanStepThroughObjCTrampoline::ShouldStop() function. Modified ProcessGDBRemote::BuildDynamicRegisterInfo(...) to be able to deal with the new generic argument registers. Modified RNBRemote::HandlePacket_qRegisterInfo() to handle the new generic argument registers on the debugserver side. Modified DNBArchMachARM::NumSupportedHardwareBreakpoints() to be able to detect how many hardware breakpoint registers there are using a darwin sysctl. Did the same for hardware watchpoints in DNBArchMachARM::NumSupportedHardwareWatchpoints(). git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131834 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
5fba9eec8d79109bf44d5b0a59dda377c65544c5 |
|
19-May-2011 |
Greg Clayton <gclayton@apple.com> |
Added the ability to sign extend a Scalar at any bit position for integer types. Added the abilty to set a RegisterValue type via accessor and enum. Added the ability to read arguments for a function for ARM if you are on the first instruction in ABIMacOSX_arm. Fixed an issue where a file descriptor becoming invalid could cause an inifnite loop spin in the libedit thread. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131610 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
da7af84c427c5c3a7b18e550c665c2f538670a34 |
|
19-May-2011 |
Greg Clayton <gclayton@apple.com> |
Added a function to lldb_private::Address: addr_t Address::GetCallableLoadAddress (Target *target) const; This will resolve the load address in the Address object and optionally decorate the address up to be able to be called. For all non ARM targets, this just essentially returns the result of "Address::GetLoadAddress (target)". But for ARM targets, it checks if the address is Thumb, and if so, it returns an address with bit zero set to indicate a mode switch to Thumb. This is how we need function pointers to be for return addresses and when resolving function addresses for the JIT. It is also nice to centralize this in one spot to avoid having multiple copies of this code. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131588 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
b9e8f6e7a374d9313f89193e90ae41ef91712e5b |
|
18-May-2011 |
Greg Clayton <gclayton@apple.com> |
Added a way to resolve an load address from a target: bool Address::SetLoadAddress (lldb::addr_t load_addr, Target *target); Added an == and != operator to RegisterValue. Modified the ThreadPlanTracer to use RegisterValue objects to store the register values when single stepping. Also modified the output to be a bit less wide. Fixed the ABIMacOSX_arm to not overwrite stuff on the stack. Also made the trivial function call be able to set the ARM/Thumbness of the target correctly, and also sets the return value ARM/Thumbness. Fixed the encoding on the arm s0-s31 and d16 - d31 registers when the default register set from a standard GDB server register sets. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131517 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
d45c3d7d55439692aa3215a709046944353b5917 |
|
16-May-2011 |
Greg Clayton <gclayton@apple.com> |
Added the ability to get a 32 or 64 bit simple return value from the ABIMacOSX_arm plugin. Modified darwin-debug to print out the exectuable, working directory and arguments a bit differently. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131392 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
989816b9505219cd67ce044d655c54ac86ecf64b |
|
14-May-2011 |
Greg Clayton <gclayton@apple.com> |
Expand the ABI prepare trivial function call to allow 6 simple args. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131334 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
61d4f7adb6936a6d406dd5b20452d0843e538d76 |
|
12-May-2011 |
Greg Clayton <gclayton@apple.com> |
Cleaned up the ABI::PrepareTrivialCall() function to take three argument pointers: virtual bool PrepareTrivialCall (Thread &thread, lldb::addr_t sp, lldb::addr_t functionAddress, lldb::addr_t returnAddress, lldb::addr_t *arg1_ptr, lldb::addr_t *arg2_ptr, lldb::addr_t *arg3_ptr) const = 0; Prior to this it was: virtual bool PrepareTrivialCall (Thread &thread, lldb::addr_t sp, lldb::addr_t functionAddress, lldb::addr_t returnAddress, lldb::addr_t arg, lldb::addr_t *this_arg, lldb::addr_t *cmd_arg) const = 0; This was because the function that called this slowly added more features to be able to call a C++ member function that might have a "this" pointer, and then later added "self + cmd" support for objective C. Cleaning this code up and the code that calls it makes it easier to implement the functions for new targets. The MacOSX_arm::PrepareTrivialCall() is now filled in and ready for testing. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131221 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|
75906e4ec98af3717e415727a8d663a4e246bb4f |
|
11-May-2011 |
Greg Clayton <gclayton@apple.com> |
Moved all code from ArchDefaultUnwindPlan and ArchVolatileRegs into their respective ABI plugins as they were plug-ins that supplied ABI specfic info. Also hookep up the UnwindAssemblyInstEmulation so that it can generate the unwind plans for ARM. Changed the way ABI plug-ins are handed out when you get an instance from the plug-in manager. They used to return pointers that would be mananged individually by each client that requested them, but now they are handed out as shared pointers since there is no state in the ABI objects, they can be shared. git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@131193 91177308-0d34-0410-b5e6-96231b3b80d8
/external/lldb/source/Plugins/ABI/MacOSX-arm/ABIMacOSX_arm.cpp
|