summaryrefslogtreecommitdiffstats
path: root/lldb
Commit message (Collapse)AuthorAgeFilesLines
* Avoid the race condition Stephen Wilson was worried about in revision 123465 ↵Greg Clayton2011-01-221-5/+8
| | | | | | by making a local copy. We need to be able to have the private state thread let the lldb_private::Process class that it has exited, otherwise we end up with a timeout when the process destructor or DoDestroy is called where the private state thread has already exited and then StopPrivateStateThread() will wait for the thread which has already existed to respond to it. llvm-svn: 124038
* Sped up the shutdown time on MacOSX by quite a bit by making sure anyGreg Clayton2011-01-227-61/+60
| | | | | | | | | | | | | | | | | threads that we spawn let us know when they are going away and that we don't timeout waiting for a message from threads that have gone away. We also now don't expect the "k" packet (kill) to send a response. This greatly speeds up debugger shutdown performance. The test suite now runs quite a bit faster. Added a fix to the variable display code that fixes the display of base classes. We were assuming the virtual or normal base class offsets were being given in bit sizes, but they were being given as character sizes, so we needed to multiply the offset by 8. This wasn't affecting the expression parser, but it was affecting the correct display of C++ class base classes and all of their children. llvm-svn: 124024
* Added an interface for noticing new thread creation. At this point, I only ↵Jim Ingham2011-01-224-1/+133
| | | | | | | | | | turn it on when we are requesting a single thread to run. May seem like a silly thing to do, but the kernel on MacOS X will inject new threads into a program willy-nilly, and I would like to keep them from running if I can. llvm-svn: 124018
* Add more logging. Try to handle the case where "Halt" fails. This is kind ↵Jim Ingham2011-01-221-5/+47
| | | | | | of a losing game in the end, if we can't halt the target, it is not clear what we can do but keep trying... llvm-svn: 124017
* Centralize the register reporting (might want to move this function to Thread).Jim Ingham2011-01-221-0/+2
| | | | llvm-svn: 124016
* Centralize the register reporting (might want to move this function to Thread).Jim Ingham2011-01-221-30/+34
| | | | | | | Make sure DoTakedown gets called only once by adding a dedicated m_takedown_done bool. Add a little more useful logging. llvm-svn: 124015
* Move some of the more noisy "log enable lldb expression" output to the ↵Jim Ingham2011-01-223-11/+11
| | | | | | verbose output. llvm-svn: 124014
* Make "log enable -v" work. We were only checking the log's stream's ↵Jim Ingham2011-01-221-0/+4
| | | | | | verbosity, not the log's verbosity... llvm-svn: 124013
* Add a (currently disabled) bear trap where instead of deallocating pages, we ↵Jim Ingham2011-01-221-2/+9
| | | | | | remove all permissions. llvm-svn: 124012
* Add API and implementation for SBDebugger::Destroy and Debugger::Destroy.Caroline Tice2011-01-224-1/+45
| | | | llvm-svn: 124011
* Add more descriptions to the g_arm_opcodes table entries.Johnny Chen2011-01-221-3/+5
| | | | llvm-svn: 124010
* Pass along (ARMEncoding)encoding as the callback data, which allows us to ↵Johnny Chen2011-01-221-8/+20
| | | | | | | | | abstract the EmulateCallback routine without too much duplication. Add an entry for emulating ARM PUSH with encoding A2. llvm-svn: 124009
* Add missing {} so we don't print the Baton address for the brief breakpoint ↵Jim Ingham2011-01-221-1/+3
| | | | | | listing. llvm-svn: 124008
* Untabify the file.Johnny Chen2011-01-211-5/+5
| | | | llvm-svn: 124003
* Added a safeguard to ensure that the user does not create variables that ↵Sean Callanan2011-01-211-2/+16
| | | | | | override persistent result variables. llvm-svn: 124001
* The code to check whether the number of arguments was 0 was not necessary, ↵Jim Ingham2011-01-211-7/+0
| | | | | | VerifyBreakpointIDs will turn an empty argument into the last specified breakpoint. llvm-svn: 124000
* Added the start of opcode emulation for ARM instructions. This class is designedGreg Clayton2011-01-215-0/+712
| | | | | | | | | | | | | | | to be fed 4 callbacks: read/write memory, and read/write registers. After this, you can tell the object to read an instruction. This will cause the class to read the PC, and read and instruction. Then you can emulate the instruction by calling EvaluateInstruction. This will cause the class to figure out exactly what an opcode does, and call the read/write mem/regs functions with actual values which allows one to emulate an instruction without running a process, or it allows one to watch the context information (the memory write is a pushing register 3 onto the stack at offset 12) so it can be used for generating call frame information. This way, in the future, we will have one class that can be used to emulate instructions and generate our unwind info from assembly. llvm-svn: 123998
* Add test cases for the scenario of selecting a frame index while stopped, andJohnny Chen2011-01-213-0/+148
| | | | | | | then doing a thread step-out. This should lead us to the caller frame of the frame we just selected. llvm-svn: 123984
* Added support for stepping out of a frame. If you have 10 stack frames, and you Greg Clayton2011-01-2116-84/+328
| | | | | | | | | | select frame #3, you can then do a step out and be able to go directly to the frame above frame #3! Added StepOverUntil and StepOutOfFrame to the SBThread API to allow more powerful stepping. llvm-svn: 123970
* Fixed up the SBValue::GetExpressionPath() to be more correct under moreGreg Clayton2011-01-2110-105/+145
| | | | | | circumstances. llvm-svn: 123957
* Added the ability to StackFrame::GetValueForVariableExpressionPath(...) to avoidGreg Clayton2011-01-204-6/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | fragile ivars if requested. This was done by changing the previous second parameter to an options bitfield that can be populated by logical OR'ing the new StackFrame::ExpressionPathOption enum values together: typedef enum ExpressionPathOption { eExpressionPathOptionCheckPtrVsMember = (1u << 0), eExpressionPathOptionsNoFragileObjcIvar = (1u << 1), }; So the old function was: lldb::ValueObjectSP StackFrame::GetValueForVariableExpressionPath (const char *var_expr, bool check_ptr_vs_member, Error &error); But it is now: lldb::ValueObjectSP StackFrame::GetValueForVariableExpressionPath (const char *var_expr, uint32_t options, Error &error); This allows the expression parser in Target::EvaluateExpression(...) to avoid using simple frame variable expression paths when evaluating something that might be a fragile ivar. llvm-svn: 123938
* Remove the expectedFailure decorators. The bug:Johnny Chen2011-01-201-4/+0
| | | | | | | | rdar://problem/8875425 Found mySource->isa local variable assertion failed has been fixed. llvm-svn: 123924
* Fixed the async packets (packets that need to be sent to the GDB server Greg Clayton2011-01-202-8/+25
| | | | | | | | | | | while the inferior is running) to be fast. The previous code would always cause the sender to timeout, yet still return success due to the way we were waiting for a value (incorrect value) to change. Now the ProcessGDBRemote plug-in has a public and private "is running" predicate. This allows things that need to send async packets to interrupt and wait for the private "is running" state to be flipped to false, and then resume quickly with no timeout. llvm-svn: 123903
* Made the DWARF + debug map symbol file parser be much more efficient when it ↵Greg Clayton2011-01-203-6/+36
| | | | | | | | | | isn't going to actually be used as the symbol file plug-in by looking only for suitable N_OSO symbols and avoiding sorting function (N_FUN) and global/static (N_GSYM/N_STSYM) symbols when there are no suitable N_OSO objects. llvm-svn: 123889
* Fixed the auto completion of objective C types with the new ExternalASTSource Greg Clayton2011-01-202-11/+25
| | | | | | changes that recently happened. llvm-svn: 123881
* Back up both the register AND the stop state when calling functions.Jim Ingham2011-01-2014-57/+181
| | | | | | | Set the thread state to "bland" before calling functions so they don't inherit the pending signals and die. llvm-svn: 123869
* Make expressions clean up their JIT'ed code allocation.Greg Clayton2011-01-1913-89/+133
| | | | llvm-svn: 123855
* Add the cmdline to invoke the Python profile reporting module.Johnny Chen2011-01-191-1/+3
| | | | llvm-svn: 123844
* Print out the command line used to invoke the test suite so I don't get confusedJohnny Chen2011-01-191-0/+8
| | | | | | since different options can affect the run time. llvm-svn: 123843
* Fix a typo in the comment.Johnny Chen2011-01-191-1/+1
| | | | llvm-svn: 123840
* ThreadPlanCallUserExpression's WillPop needs to call it's parent's WillPop.Jim Ingham2011-01-192-0/+4
| | | | llvm-svn: 123816
* Took the timeout for a ClangUserExpression down from a 10 second timeout toGreg Clayton2011-01-199-163/+117
| | | | | | | | | | | | | | 500 ms. Make MachThreadList more threadsafe. Added code to make sure the thread register state was properly flushed for x86_64. Fixed an missing return code for the current thread in the new thread suffix code. Improved debugserver logging. llvm-svn: 123815
* Added special logic to faciliate profiling the test suite run with the ↵Johnny Chen2011-01-192-1/+13
| | | | | | | | | | | | | | cProfile.py module. On my MBP running SnowLeopard: $ DOTEST_PROFILE=YES DOTEST_SCRIPT_DIR=/Volumes/data/lldb/svn/trunk/test /System/Library/Frameworks/Python.framework/Versions/Current/lib/python2.6/cProfile.py -o my.profile ./dotest.py -v -w 2> ~/Developer/Log/lldbtest.log After that, I used the pstats.py module to browse the statistics recorded in the my.profile file. llvm-svn: 123807
* The test suite was unnecessarily doing a time.sleep() after performing theJohnny Chen2011-01-191-4/+2
| | | | | | | | "process launch" or "run" interpreter command. Let's do the sleep only if the process launch failed. This saves about 135 seconds from the whole test suite run time. llvm-svn: 123806
* Delay sync with the parent thread in ProcessLinux/ProcessMonitor.Stephen Wilson2011-01-192-5/+8
| | | | | | | This patch removes a potential race condition between a process monitor thread and its parent waiting to interrogate the success/failure of the launch. llvm-svn: 123803
* Make LinuxThread use the LLDB unwinder.Stephen Wilson2011-01-192-3/+17
| | | | llvm-svn: 123801
* Do not enable hardware stepping when resuming a step-enabled thread.Stephen Wilson2011-01-191-1/+1
| | | | | | | The previous implementation of HardwareSingleStep wrongly resumed the thread and single-stepped over the next instruction. Use the proper call to ProcessMonitor. llvm-svn: 123800
* Fix implementation of LinuxThread::HardwareSingleStep.Stephen Wilson2011-01-191-1/+22
| | | | | | | | Previous version simply resumed the associated thread to single step over a single instruction which is not the intended semantics for this method. Set the appropriate bit in the rflags register instead. llvm-svn: 123799
* Implement RegisterContextLinux_x86_64::ReadRegisterBytes.Stephen Wilson2011-01-192-10/+59
| | | | | | | Also, this patch adds a few delimiters to the register enumeration to enable efficient testing of register set inclusion. llvm-svn: 123798
* Support the reading of registers en masse via the linux ProcessMonitor.Stephen Wilson2011-01-192-0/+78
| | | | llvm-svn: 123797
* Timeout if we fail to receive a state change event when destroying an inferior.Stephen Wilson2011-01-191-4/+12
| | | | llvm-svn: 123796
* Only enqueue valid ProcessLinux messages.Stephen Wilson2011-01-191-1/+5
| | | | llvm-svn: 123795
* Load dependent modules in the Linux dynamic loader.Stephen Wilson2011-01-191-0/+7
| | | | | | | This fixes a bug where the dynamic loader rendezvous was not updating its internal state when first initialized. llvm-svn: 123794
* Decorated two new expected failures:Johnny Chen2011-01-191-0/+4
| | | | | | rdar://problem/8875425 Found mySource->isa local variable assertion failed llvm-svn: 123792
* Updated to revision 123723 of LLVM, to bring inSean Callanan2011-01-186-28/+34
| | | | | | support for minimal type import functionality. llvm-svn: 123787
* Make a few log messages come out in "log enable lldb step" as well as "log ↵Jim Ingham2011-01-182-3/+5
| | | | | | enable lldb expression". llvm-svn: 123784
* Remove trailing commas from lldb enumerations (patch from Stephen Wilson).Greg Clayton2011-01-181-5/+5
| | | | llvm-svn: 123782
* Use generic CPU types instead of hard coding to mach-o when getting default ↵Greg Clayton2011-01-181-6/+6
| | | | | | byte order (patch from Stephen Wilson). llvm-svn: 123781
* Fixed incorrect logging printf (patch from Stephen Wilson).Greg Clayton2011-01-181-1/+1
| | | | llvm-svn: 123780
* Fixed missing return value (patch from Stephen Wilson).Greg Clayton2011-01-181-1/+1
| | | | llvm-svn: 123779
OpenPOWER on IntegriCloud