summaryrefslogtreecommitdiffstats
path: root/lldb/source/Interpreter
Commit message (Collapse)AuthorAgeFilesLines
...
* Quiet unused variable warning that only occursEric Christopher2014-09-091-0/+1
| | | | | | when compiling optimized. llvm-svn: 217429
* Fix configure & make build with python disabledKeno Fischer2014-09-091-0/+5
| | | | | | | | | | | | | This makes sure that nothing that requires Python is being built when the LLDB_DISABLE_PYTHON flag is being passed in. It also changes a use of CPPFLAGS to CPP.Flags since the former is overridden when external flags are passed in while the later is not. I'm not sure exactly why LLDB_DISABLE_PYTHON is in CXXFLAGS rather than CPPFLAGS, but cleaning that up is for another commit. Differential Revision: http://reviews.llvm.org/D4918 llvm-svn: 217414
* Add a -V <bool> flag to frame variable/expression that enables execution of ↵Enrico Granata2014-09-061-0/+11
| | | | | | type validators. The jury is still out on what the user experience of type validators should be, so for now gate it on a specific flag. The mode I am using is prefix variables that fail to validate with a bang, and then emitting the actual validation error on a separate line. Of course, given the total absence of validators, this should never actually happen to you llvm-svn: 217303
* Allow "breakpoint command add" to add commands to more than one breakpoint ↵Jim Ingham2014-08-292-20/+48
| | | | | | | | at a time. <rdar://problem/13314462> llvm-svn: 216747
* A quoted - is not the beginning of an option, and should not be completed as ↵Jim Ingham2014-08-271-0/+2
| | | | | | | | | | | | such. This was causing: (lldb) disassemble -n '-<TAB> to crash. <rdar://problem/18134531> llvm-svn: 216626
* Move the rest of the HostInfo functions over.Zachary Turner2014-08-211-2/+7
| | | | | | | | | This should bring HostInfo up to 99% completion. The remainder of code in Host will be split into instantiatable classes representing host processes, threads, dynamic libraries, and process launching strategies. llvm-svn: 216230
* Move Host::GetLLDBPath to HostInfo.Zachary Turner2014-08-211-4/+4
| | | | | | | | This continues the effort to get Host code moved over to HostInfo, and removes many more instances of preprocessor defines along the way. llvm-svn: 216195
* Remove another of the llvm given warnings from the list ofEric Christopher2014-08-151-3/+4
| | | | | | warnings we compile with because of SWIG generated code. llvm-svn: 215778
* fix the _regexp-break command to allow quotes around the name:Greg Clayton2014-08-141-1/+1
| | | | | | | | (lldb) b "Foo::Bar::Baz" <rdar://problem/11782098> llvm-svn: 215668
* Don't enable STDIN for cases where we are supplying lines to be run in the ↵Greg Clayton2014-08-141-2/+2
| | | | | | | | embedded python interpreter. <rdar://problem/17949057> llvm-svn: 215608
* Fix some python shutdown / ordering issues.Zachary Turner2014-08-081-1/+5
| | | | | | | | Differential Revision: http://reviews.llvm.org/D4826 Reviewed by: Enrico Granata llvm-svn: 215256
* Probably should initialize that new ivar while I'm at it...Jim Ingham2014-08-061-0/+1
| | | | llvm-svn: 214941
* Add a variant of the CommandOverrideCallback that takes aJim Ingham2014-08-061-6/+4
| | | | | | | | | | | | | | CommandReturnObject. Otherwise, all the overridden command can do is say it overrode the command, not say what it did... Also removed the duplicate definition of CommandOverrideCallback from the private interfaces. Now to figure out how to get this through the SB API's... <rdar://problem/17911629> llvm-svn: 214938
* Fixed an issue where the LLDB command prompt isn't interactive if you use -o ↵Greg Clayton2014-07-311-22/+16
| | | | | | | | | | -O -S -s or specify a file on the command line. This means TAB completion wasn't working and editline wasn't being used. <rdar://problem/17872824> llvm-svn: 214428
* (no commit message)Greg Clayton2014-07-301-1/+12
| | | | llvm-svn: 214319
* Use llvm Support functions to get the user's home directory.Zachary Turner2014-07-281-3/+5
| | | | | | | | | | | Assuming that the user's home directory is at ~ is incorrect on Windows. This patch delegates the request to LLVM's support library, which already provides a cross-platform implementation of this function. Differential Revision: http://reviews.llvm.org/D4674 llvm-svn: 214093
* ScriptInterpreterPython: %p should be used with void-pointerDavid Majnemer2014-07-221-1/+1
| | | | | | | | | printf's %p format specifier expects an argument of type void-pointer, not type PyThreadState*. Fix this with a static_cast. Differential Revision: http://reviews.llvm.org/D4632 llvm-svn: 213695
* Test commit. Having trouble committing from one machine but notZachary Turner2014-07-181-1/+1
| | | | | | another, attempting to fix it. llvm-svn: 213413
* Fix a bug with order of operations.Zachary Turner2014-07-181-1/+1
| | | | llvm-svn: 213411
* Any commands that are executed through the public interface using ↵Greg Clayton2014-07-152-3/+19
| | | | | | | | | | | | | | SBCommandInterpreter::HandleCommand() are assumed to be in non-interactive mode. Any commands that want interactivity (stdin) will need to be executed through the normal command interpreter using the debugger's in/out/err file handles, or by using "command source". Individual commands through the API will have their STDIN disabled. The STDOUT and STDERR will be redirected into the SBCommandReturnObject argument to SBCommandInterpreter::HandleCommand() as usual. This helps with a deadlock situation in an IDE (Xcode) where the IDE was managing the breakpoint actions by setting a breakpoint callback and doing things manually. <rdar://problem/17386271> llvm-svn: 213023
* Get the python scripting interface working on Windows.Zachary Turner2014-07-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes a number of issues with embedded Python on Windows. In particular: 1) The script that builds the python modules was normalizing the case of python filenames during copies. The module name is the filename, and is case-sensitive, so this was breaking code. 2) Changes the build to not attempt to link against python27.lib (e.g. the release library) when linking against msvcrt debug library. Doing a debug build of LLDB with embedded python support now requires you to provide your own self-compiled debug version of python. 3) Don't import termios when initializing the interpreter. This is part of a larger effort to remove the dependency on termios since it is not available on Windows. This particular instance was unnecessary and unused. Reviewed by: Todd Fiala Differential Revision: http://reviews.llvm.org/D4441 llvm-svn: 212785
* Fix tests broken by the OptionValidator changes.Zachary Turner2014-07-094-0/+5
| | | | | | | | | | | | | | | | | | | | | | | The getopt library has a structure called option (lowercase). We have a structure called Option (uppercase). previously the two structures had exactly the same definitions, and we were doing a C-style cast of an Option* to an option*. C-style casts don't bother to warn you when you cast to unrelated types, but in the original OptionValidator patch I modified the definition of Option. This patch fixes the errors by building an array of option structures and filling it out the correct way before passing it to the getopt library. This also fixes one other source of test failures: an uninitialized read that occurs due to not initializing a field of the OptionDefinition. Reviewed By: Todd Fiala Differential Revision: http://reviews.llvm.org/D4425 llvm-svn: 212628
* Revert "Fix broken tests due to new error output."Zachary Turner2014-07-0912-68/+132
| | | | | | | This reverts commit ec7c94f8e6860968d384b578e5564a9c55c80b4a and re-enables OptionValidators. llvm-svn: 212627
* __arm64__ and __aarch64__ #ifdef adjustmentsTodd Fiala2014-07-091-1/+1
| | | | | | | | Change by Paul Osmialowski See http://reviews.llvm.org/D4379 for details. llvm-svn: 212583
* Fix broken tests due to new error output.Todd Fiala2014-07-0812-132/+68
| | | | | | | | | | | This reverses out the options validators changes. We'll get these back in once the changes to the output can be resolved. Restores broken tests on FreeBSD, Linux, MacOSX. Changes reverted: r212500, r212317, r212290. llvm-svn: 212543
* Fix a compilation failure caused by a non-const reference.Zachary Turner2014-07-081-1/+1
| | | | llvm-svn: 212509
* Invalidate process UID/GID-related command options on Windows.Zachary Turner2014-07-074-33/+97
| | | | | | | | | | | | Windows uses a different process security model and does not have a concept of process UID or GID. This patch makes these options invalid on Windows. Attempting to specify these options when the current platform is Windows will generate an error. Reviewed by: Jim Ingham Differential Revision: http://reviews.llvm.org/D4373 llvm-svn: 212500
* Windows build fixes and removal of endlessly recursive termination function.Todd Fiala2014-07-041-9/+0
| | | | | | | | | | | | | This change removes the ScriptInterpreter::TerminateInterpreter() call which ended up endlessly calling itself as things currently stand. It also cleans up some other Windows-related cmake changes. See http://lists.cs.uiuc.edu/pipermail/lldb-commits/Week-of-Mon-20140630/011544.html for more details. Change by Zachary Turner llvm-svn: 212320
* Adds the notion of an OptionValidator.Zachary Turner2014-07-039-35/+35
| | | | | | | | | | | | | | | | | | The purpose of the OptionValidator is to determine, based on some arbitrary set of conditions, whether or not a command option is valid for a given debugger state. An example of this might be to selectively disable or enable certain command options that don't apply to a particular platform. This patch contains no functional change, and does not actually make use of an OptionValidator for any purpose yet. A follow-up patch will begin to add the logic and users of OptionValidator. Reviewed by: Greg Clayton, Jim Ingham Differential Revision: http://reviews.llvm.org/D4369 llvm-svn: 212290
* Add host layer support for pipes.Greg Clayton2014-07-021-12/+8
| | | | | | | | | | | Windows does support pipes, but they do so in a slightly different way. Added a Host layer which abstracts the use of pipes into a new Pipe class that everyone can use. Windows benefits include: - Being able to interrupt running processes when IO is directly hooked up - being able to interrupt long running python scripts - being able to interrupt anything based on ConnectionFileDescriptor llvm-svn: 212220
* This creates a valid Python API for Windows, pending some issues. The ↵Deepak Panickal2014-07-011-0/+5
| | | | | | | | | | | | | changes included are - - Ported the SWIG wrapper shell scripts to Python so that they would work on Windows too along with other platforms - Updated CMake handling to fix SWIG errors and manage sym-linking on Windows to liblldb.dll - More build fixes for Windows The pending issues are that two Python modules, termios and pexpect are not available on Windows. These are currently required for the Python command interpreter to be used from within LLDB. llvm-svn: 212111
* lldb: remove adhoc implementation of array_sizeofSaleem Abdulrasool2014-06-272-2/+5
| | | | | | | | Replace adhoc inline implementation of llvm::array_lengthof in favour of the implementation in LLVM. This is simply a cleanup change, no functional change intended. llvm-svn: 211868
* Fix a few typos.Bruce Mitchener2014-06-271-2/+2
| | | | llvm-svn: 211851
* Interpreter: kill some dead codeSaleem Abdulrasool2014-06-131-4/+1
| | | | | | | Remove commented out code and an unnecessary associated scope. No functional change. llvm-svn: 210882
* Interpreter: explicitly initialize base classSaleem Abdulrasool2014-06-131-0/+1
| | | | | | | Initialise base class std::enable_shared_from_this explicitly. Identified by GCC. llvm-svn: 210881
* Remove unused variablesSaleem Abdulrasool2014-06-131-3/+0
| | | | | | | | Address the 'variable set but not used' warning from GCC. In some cases a few additional calls were removed where there should be no visible side effects of the calls (i.e. should not effect any cached state). llvm-svn: 210879
* Args::StringToGenericRegister will now accept "lr" as Jason Molenda2014-05-091-1/+1
| | | | | | | | | | | | | another way to indicate that this register is a generic Return Address register (in addition to "ra") - this is used primarily by OperatingSystem plugins. Correctly annotate the UnwindPlan created by EmulateInstructionARM64 to indicate that it was not sourced from a compiler and it is valid at every instruction. <rdar://problem/16639754> llvm-svn: 208390
* lldb TOT is dropping the last entry for multi-line IOHandlers that use the ↵Greg Clayton2014-05-081-1/+1
| | | | | | | | IOHandlerDelegateMultiline. <rdar://problem/16844164> llvm-svn: 208336
* Rename eExecution*** to eExpression*** to be consistent with the result type.Jim Ingham2014-05-052-11/+11
| | | | llvm-svn: 207945
* Make the Expression Execution result enum available to the SB API layer.Jim Ingham2014-05-052-2/+7
| | | | | | | | | Add a callback that will allow an expression to be cancelled between the expression evaluation stages (for the ClangUserExpressions.) <rdar://problem/16790467>, <rdar://problem/16573440> llvm-svn: 207944
* "DONE" is being left in multi-line results when it shouldn't for non ↵Greg Clayton2014-05-021-1/+1
| | | | | | | | terminal input. <rdar://problem/16790579> llvm-svn: 207818
* Fixed CTRL+C related issues:Greg Clayton2014-05-022-11/+45
| | | | | | | | | | | | - CTRL+C wasn't clearing the command in lldb - CTRL+C doesn't work in python macros in lldb - Ctrl+C no longer interrupts the running process that you attach to <rdar://problem/15949205> <rdar://problem/16778652> <rdar://problem/16774411> llvm-svn: 207816
* Free the strong reference to a lldb::SBDebugger that the script interpreter ↵Greg Clayton2014-04-252-0/+14
| | | | | | was holding onto in the "lldb.debugger" global variable. llvm-svn: 207292
* Make sure that the CommandInterpreter::m_command_io_handler_sp gets reset ↵Greg Clayton2014-04-251-0/+6
| | | | | | | | | | when we quit. Currently if you run _any_ python, python has the "lldb.debugger" global variable and it has a strong reference to a lldb_private::Debugger since it is a lldb::SBDebugger object with a shared pointer. This makes sure that your LLDB command interpreter history is saved each time you quit command line LLDB. llvm-svn: 207164
* Switch NULL to C++11 nullptr in source/InterpreterEd Maste2014-04-2033-399/+399
| | | | | | Patch by Robert Matusewicz llvm-svn: 206711
* Cleanup the code a bit.Greg Clayton2014-04-071-1/+1
| | | | llvm-svn: 205739
* Remember to clear the cached data for the OptionValueFileSpec in ↵Jim Ingham2014-04-041-0/+1
| | | | | | | | SetValueFromCString. <rdar://problem/16179718> target.expr-prefix contents appear to be cached for an entire session llvm-svn: 205636
* sanitise sign comparisonsSaleem Abdulrasool2014-04-025-8/+9
| | | | | | | | This is a mechanical change addressing the various sign comparison warnings that are identified by both clang and gcc. This helps cleanup some of the warning spew that occurs during builds. llvm-svn: 205390
* Add the ability to set python breakpoint commands from the SBBreakpoint & ↵Jim Ingham2014-04-021-32/+54
| | | | | | | | | | | SBBreakpointLocation API's. You can either provide the function name, or function body text. Also propagate the compilation error up from where it is checked so we can report compilation errors. <rdar://problem/9898371> llvm-svn: 205380
* lldb arm64 import.Jason Molenda2014-03-291-1/+1
| | | | | | | | | | | | | | | | These changes were written by Greg Clayton, Jim Ingham, Jason Molenda. It builds cleanly against TOT llvm with xcodebuild. I updated the cmake files by visual inspection but did not try a build. I haven't built these sources on any non-Mac platforms - I don't think this patch adds any code that requires darwin, but please let me know if I missed something. In debugserver, MachProcess.cpp and MachTask.cpp were renamed to MachProcess.mm and MachTask.mm as they picked up some new Objective-C code needed to launch processes when running on iOS. llvm-svn: 205113
OpenPOWER on IntegriCloud