summaryrefslogtreecommitdiffstats
path: root/lldb/test/functionalities
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix TestCommandScript: return an error if target executable is not setEd Maste2015-05-281-3/+7
| | | | | | | | | | The test invokes the 'targetname' test command before setting a target executable, which caused Python to raise TypeError: cannot concatenate 'str' and 'NoneType' objects. llvm.org/pr23686 llvm-svn: 238425
* Cleanup the forked child in TestChangeProcessGroupPavel Labath2015-05-281-0/+8
| | | | | | | if the test fails for some reason, we can end up leaking a process. This has a tendency to confuse the buildbots. I have added a cleanup hook to make sure we cleanup the child. llvm-svn: 238421
* Don't check breakpoint location count in TestChangeProcessGroupPavel Labath2015-05-281-1/+1
| | | | | | apparently, we get two locations for the breakpoint on android. llvm-svn: 238417
* Move prctl call in TestChangeProcessGroup to the childPavel Labath2015-05-281-13/+13
| | | | | | I was hoping the enable-tracing flag will be inherited from the parent. It is not. llvm-svn: 238408
* [NativeProcessLinux] Support inferiors which change their process groupPavel Labath2015-05-283-0/+200
| | | | | | | | | | | | | | | | | | | | Summary: Previously, we wait()ed for events from the inferiors process group. This is resulted in a failure if the inferior changed its process group in the middle of execution. To avoid this, I pass -1 to the wait() call. The flag __WNOTHREAD makes sure we don't actually wait for events from any process, but only the processes(threads) which are our children (or traced by us). Since this happens on the monitor thread, which is dedicated to monitoring a single inferior, we will be getting events only from this inferior. Test Plan: All tests pass on linux. I have added a test to check the new functionality. Reviewers: chaoren, ovyalov Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D10061 llvm-svn: 238405
* [TestDataFormatterUnordered] Use patterns to match unordered_<multi>set elementsSiva Chandra2015-05-281-8/+8
| | | | | | | | | | | | | | | | Summary: This fixes the test for i386 targets. Test Plan: dotest.py -C clang --arch i386 TestDataFormatterUnordered Reviewers: chying, chaoren, clayborg Reviewed By: clayborg Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D10078 llvm-svn: 238385
* [TestBase.runCmd] Better error message when runCmd fails.Siva Chandra2015-05-2797-148/+148
| | | | | | | | | | | | | | | | | | | | | Summary: Before: AssertionError: False is not True : Process is launched successfully After: AssertionError: False is not True : Command 'run a.out' failed. >>> error: invalid target, create a target using the 'target create' command >>> Process could not be launched successfully Reviewers: clayborg Reviewed By: clayborg Subscribers: lldb-commits, vharron Differential Revision: http://reviews.llvm.org/D9948 llvm-svn: 238363
* [TestDataFormatterUnordered] Fix a few typos in the test.Siva Chandra2015-05-271-2/+2
| | | | | | | | | | | | | | | | Summary: The typos were exposed by http://reviews.llvm.org/D9948. Test Plan: dotest.py -p TestDataFormatterUnordered Reviewers: vharron, clayborg Reviewed By: clayborg Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D10071 llvm-svn: 238361
* Add support for custom commands to set flags on themselvesEnrico Granata2015-05-273-13/+23
| | | | | | | | | This works for Python commands defined via a class (implement get_flags on your class) and C++ plugin commands (which can call SBCommand::GetFlags()/SetFlags()) Flags allow features such as not letting the command run if there's no target, or if the process is not stopped, ... Commands could always check for these things themselves, but having these accessible via flags makes custom commands more consistent with built-in ones llvm-svn: 238286
* Disable TestConcurrentEvents.py on Windows.Zachary Turner2015-05-221-1/+1
| | | | | | | This test takes over 5 minutes to run just by itself, and everything fails anyway, so it doesn't make sense to keep it running for now. llvm-svn: 238040
* [TestRaise] Skip the SIGRTMIN test on Android.Siva Chandra2015-05-221-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Running "kill -l" on nexus player (i386) device results in this: 1 HUP Hangup 33 33 Signal 33 2 INT Interrupt 34 34 Signal 34 3 QUIT Quit 35 35 Signal 35 4 ILL Illegal instruction 36 36 Signal 36 5 TRAP Trap 37 37 Signal 37 6 ABRT Aborted 38 38 Signal 38 7 BUS Bus error 39 39 Signal 39 8 FPE Floating point exception 40 40 Signal 40 9 KILL Killed 41 41 Signal 41 10 USR1 User signal 1 42 42 Signal 42 11 SEGV Segmentation fault 43 43 Signal 43 12 USR2 User signal 2 44 44 Signal 44 13 PIPE Broken pipe 45 45 Signal 45 14 ALRM Alarm clock 46 46 Signal 46 15 TERM Terminated 47 47 Signal 47 16 STKFLT Stack fault 48 48 Signal 48 17 CHLD Child exited 49 49 Signal 49 18 CONT Continue 50 50 Signal 50 19 STOP Stopped (signal) 51 51 Signal 51 20 TSTP Stopped 52 52 Signal 52 21 TTIN Stopped (tty input) 53 53 Signal 53 22 TTOU Stopped (tty output) 54 54 Signal 54 23 URG Urgent I/O condition 55 55 Signal 55 24 XCPU CPU time limit exceeded 56 56 Signal 56 25 XFSZ File size limit exceeded 57 57 Signal 57 26 VTALRM Virtual timer expired 58 58 Signal 58 27 PROF Profiling timer expired 59 59 Signal 59 28 WINCH Window size changed 60 60 Signal 60 29 IO I/O possible 61 61 Signal 61 30 PWR Power failure 62 62 Signal 62 31 SYS Bad system call 63 63 Signal 63 32 32 Signal 32 64 64 Signal 64 The signals from 33-64 are missing symbolic names. Test Plan: dotest.py -p TestRaise on Android Reviewers: labath Subscribers: tberghammer, aemerson, lldb-commits Differential Revision: http://reviews.llvm.org/D9944 llvm-svn: 238039
* Add real time signals support to LinuxSignalsPavel Labath2015-05-222-21/+107
| | | | | | | | | | | | | | Summary: This enables correct handling of real time signals by lldb. Test Plan: Added a test that verifies handling of SIGRTMIN Reviewers: tberghammer, ovyalov Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D9911 llvm-svn: 238009
* TestInlineStepping - made XFAIL more specificVince Harron2015-05-211-1/+2
| | | | | | Differential Revision: http://reviews.llvm.org/D9828 llvm-svn: 237921
* Update Makefile to reflect that TestNumThreads now uses std::thread instead ↵Adrian McCarthy2015-05-211-1/+1
| | | | | | of pthreads. llvm-svn: 237919
* XFAILing TestRaise on darwin due to an apparent bugPavel Labath2015-05-211-0/+2
| | | | llvm-svn: 237887
* [NativeProcessLinux] Fix handling of SIGSTOPPavel Labath2015-05-213-0/+123
| | | | | | | | | | | | | | | | | | | | | | | | Summary: Previously, NPL tried to reinject SIGSTOP into the inferior in an attempt to get the process to start in the group-stop state. This was: a) wrong (reinjection should be controlled by "process handle" lldb setting) b) racy (it should use Resume for transparent resuming instead of RequestResume) c) broken (llgs crashed on inferior SIGSTOP) With this change, SIGSTOP is handled just like any other signal delivered to the inferior: we stop all threads and report signal reception to lldb. SIGSTOP reinjection does not behave the same way as it would outside the debugger, but simulating this is a hard problem and is not normally necessary. Test Plan: I have added a test which verifies we get SIGSTOP reports and we do not crash. Reviewers: ovyalov, chaoren Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D9852 llvm-svn: 237880
* Have TestNumThreads use std::thread instead of pthreads so that it can work ↵Adrian McCarthy2015-05-204-62/+57
| | | | | | cross-platform. llvm-svn: 237844
* Refactored lldb executable name discoveryVince Harron2015-05-187-7/+7
| | | | | | | | | | | | | | | | | | | | The lldb executable was referenced through the code by 7 different (effectively) global variables. global lldbExecutablePath global lldbExecutable os.environ['LLDB_EXEC'] os.environ['LLDB_TEST'] dotest.lldbExec dotest.lldbHere lldbtest.lldbExec This change uses one global variable lldbtest_config.lldbExec to replace them all. Differential Revision: http://reviews.llvm.org/D9817 llvm-svn: 237600
* Fix test expectation in TestThreadExit after r237566Tamas Berghammer2015-05-181-4/+4
| | | | llvm-svn: 237578
* Update the failure reason of TestConvenienceVariables and tighten the XFAILPavel Labath2015-05-181-1/+1
| | | | llvm-svn: 237577
* Add --move-to-nearest-code / target.move-to-nearest-code options (attempt 2)Ilia K2015-05-1810-13/+102
| | | | | | | | | | | | This patch initially was committed in r237460 but later it was reverted (r237479) due to 4 new failures: * TestExitDuringStep.py * TestNumThreads.py * TestThreadExit.py * TestThreadStates.py This patch also fixes these tests. llvm-svn: 237566
* XFAIL'd some tests that fail very, very rarelyVince Harron2015-05-162-0/+2
| | | | llvm-svn: 237515
* Reverting r237460 to fix test failures introduced on OSX & LinuxVince Harron2015-05-156-98/+9
| | | | | | | | | TestExitDuringStep.py TestNumThreads.py TestThreadExit.py TestThreadStates.py llvm-svn: 237479
* Add --move-to-nearest-code / target.move-to-nearest-code optionsIlia K2015-05-156-9/+98
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This option forces to only set a source line breakpoint when there is an exact-match This patch includes the following commits: # Add the -m/--exact-match option in "breakpoint set" command ## Add exact_match arg in BreakpointResolverFileLine ctor ## Add m_exact_match field in BreakpointResolverFileLine ## Add exact_match arg in BreakpointResolverFileRegex ctor ## Add m_exact_match field in BreakpointResolverFileRegex ## Add exact_match arg in Target::CreateSourceRegexBreakpoint ## Add exact_match arg in Target::CreateBreakpoint ## Add -m/--exact-match option in "breakpoint set" command # Add target.exact-match option to skip BP if source line doesn't match ## Add target.exact-match global option ## Add Target::GetExactMatch ## Refactor Target::CreateSourceRegexBreakpoint to accept LazyBool exact_match (was bool) ## Refactor Target::CreateBreakpoint to accept LazyBool exact_match (was bool) # Add target.exact-match test in SettingsCommandTestCase # Add BreakpointOptionsTestCase tests to test --skip-prologue/--exact-match options # Fix a few typos in lldbutil.check_breakpoint_result func # Rename --exact-match/m_exact_match/exact_match/GetExactMatch to --move-to-nearest-code/m_move_to_nearest_code/move_to_nearest_code/GetMoveToNearestCode # Add exact_match field in BreakpointResolverFileLine::GetDescription and BreakpointResolverFileRegex::GetDescription, for example: was: ``` 1: file = '/Users/IliaK/p/llvm/tools/lldb/test/functionalities/breakpoint/breakpoint_command/main.c', line = 12, locations = 1, resolved = 1, hit count = 2 1.1: where = a.out`main + 20 at main.c:12, address = 0x0000000100000eb4, resolved, hit count = 2 ``` now: ``` 1: file = '/Users/IliaK/p/llvm/tools/lldb/test/functionalities/breakpoint/breakpoint_command/main.c', line = 12, exact_match = 0, locations = 1, resolved = 1, hit count = 2 1.1: where = a.out`main + 20 at main.c:12, address = 0x0000000100000eb4, resolved, hit count = 2 ``` Test Plan: ./dotest.py -v --executable $BUILDDIR/bin/lldb functionalities/breakpoint/ ./dotest.py -v --executable $BUILDDIR/bin/lldb settings/ ./dotest.py -v --executable $BUILDDIR/bin/lldb tools/lldb-mi/breakpoint/ Reviewers: jingham, clayborg Reviewed By: clayborg Subscribers: lldb-commits, clayborg, jingham Differential Revision: http://reviews.llvm.org/D9273 llvm-svn: 237460
* Skip TestPluginCommands.py if host lldb library is incompatible with remote.Robert Flack2015-05-151-1/+1
| | | | | | | | | | | | | | | TestPluginCommands.py attempts to build a library which links against the host built lldb library. This will only work if the remote is compatible with binaries produced by the host. Test Plan: ./dotest.py $DOTEST_OPTS -v -t -p TestPluginCommands.py Test is skipped if remote platform is incompatible with host platform (i.e. mac -> linux). Differential Revision: http://reviews.llvm.org/D9770 llvm-svn: 237444
* Reverting r237392 since it broke TestNumThreads on ubuntu builder.Oleksiy Vyalov2015-05-154-57/+62
| | | | llvm-svn: 237415
* Enable multithreaded debugging on Windows.Adrian McCarthy2015-05-144-62/+57
| | | | llvm-svn: 237392
* [TestSendSignal] Include signal.h instead of sys/signal.h in the test case.Siva Chandra2015-05-141-1/+1
| | | | | | | | | | | | | | | | | | Summary: Android API-9 does not have sys/signal.h. However, all sys/signal.h has when present is an include of signal.h. Test Plan: dotest.py -p TestSendSignal on linux and Android. Reviewers: chaoren Reviewed By: chaoren Subscribers: tberghammer, lldb-commits Differential Revision: http://reviews.llvm.org/D9779 llvm-svn: 237381
* Avoid Linux-specific header in platform-independent testsEd Maste2015-05-141-3/+4
| | | | llvm-svn: 237371
* [TestAttachDenied] Use a file instead of a pipe for synchronization.Siva Chandra2015-05-142-19/+35
| | | | | | | | | | | | | | | | | | | Summary: One cannot use mknod or mkfifo on user Android devices. This commit changes the use of pipe to a file to synchronize between the inferior and the test. Test Plan: dotest.py -P TestAttachDenied Reviewers: ovyalov, chaoren Reviewed By: chaoren Subscribers: tberghammer, lldb-commits Differential Revision: http://reviews.llvm.org/D9768 llvm-svn: 237328
* Fix broken test, this wasn't supposed to get committed.Zachary Turner2015-05-131-6/+0
| | | | llvm-svn: 237291
* Fix an issue with finding python on Windows.Zachary Turner2015-05-131-0/+6
| | | | | | | | | | | | | Someone must have changed the behavior of FileSpec slightly relating to whether or not there is a trailing backslash when calling GetPath() and GetDirectory(). This caused ScriptInterpreterPython to find the wrong values when initializing sys.path, and as a result we couldn't find the lldb module. This patch fixes the issue, and also adds a test to make sure that GetDirectory() does not return a string containing a trailing slash. llvm-svn: 237282
* Check the host platform to determine logging channel to test in TestRegisters.pyRobert Flack2015-05-131-3/+5
| | | | | | | | | | | | | Checks the host platform to determine logging channel to test in TestRegisters.py as the logging runs host side. Test Plan: ./dotest.py $DOTEST_OPTS -v -t -p TestRegisters.py This passes mac -> linux as it's logging the correct channel. Differential Revision: http://reviews.llvm.org/D9755 llvm-svn: 237271
* XFAIL and Skip flaky test case on linuxTamas Berghammer2015-05-121-0/+2
| | | | llvm-svn: 237135
* Working on getting the OSX build greenVince Harron2015-05-121-0/+4
| | | | | | | | | | | | | | Added missing SBLanguageRuntime.h to lldb.xcodeproj, set to Public (fixed compile error in TestPublicAPIHeaders) Removed reference to (temporarily) missing gtest.xcodeproj Fixed TestDeadStrip compile error XFAIL TestPublicAPIHeaders - test passes but teardown command 'settings remove target.env-vars DYLD_LIBRARY_PATH' fails XFAIL TestCModules - use of undeclared identifier 'MIN' XFAIL TestModulesAutoImport - clang: error: unknown argument: '-gmodules' XFAIL TestObjCNewSyntax - expr -- @((char*)"Hello world" + 6) cannot box a string value because NSString has not been declared http://reviews.llvm.org/D9643 llvm-svn: 237085
* ["watch set" tests] Use default test case executable names.Siva Chandra2015-05-112-12/+8
| | | | | | | | | | | | | | Summary: This change similar to r236783. Reviewers: chaoren Reviewed By: chaoren Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D9630 llvm-svn: 237010
* New test for llvm.org/pr23478Tamas Berghammer2015-05-113-0/+106
| | | | | | | | | | When there is two brekapoint on two consecutive instruction then the second breakpoint is ignored by lldb. This test check for the correct behaviour in this scenario. Differential revision: http://reviews.llvm.org/D9661 llvm-svn: 236997
* Skip and XFAIL TestThreadStepOut as it times out on the Linux build botTamas Berghammer2015-05-111-0/+6
| | | | llvm-svn: 236986
* Skip and XFAIL test occasionally timing out on the Linux build botTamas Berghammer2015-05-111-0/+2
| | | | llvm-svn: 236984
* Skip tests that are timing out on the FreeBSD buildbotEd Maste2015-05-093-0/+33
| | | | | | | | | XFAILing these does not work because the timeout is caught by the top-level test infrastucture instead. Some might be llvm.org/pr22784 llvm-svn: 236924
* [TestCreateAfterAttach] Add @skipIfRemote to the forking test.Siva Chandra2015-05-081-0/+1
| | | | | | | | | | | | | | Test Plan: dotest.py -p TestCreateAfterAttach Reviewers: chaoren Reviewed By: chaoren Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D9617 llvm-svn: 236903
* Skip tests that are timing out on the FreeBSD buildbotEd Maste2015-05-081-0/+30
| | | | | | | | | XFAILing these does not work because the timeout is caught by the top-level test infrastucture instead. Might be llvm.org/pr22784 llvm-svn: 236895
* Add expectedFailureFreeBSD decorator for buildbot pexpect issueEd Maste2015-05-084-0/+4
| | | | | | | | | | I'm not yet sure what's wrong with pexpect and I cannot reproduce this problem locally. XFAIL these tests for now to reduce buildbot noise so I can track down the remaining buildbot failures. llvm.org/pr22784 llvm-svn: 236857
* [TestWatchpointMultipleThreads] Use default test executable names.Siva Chandra2015-05-071-15/+10
| | | | | | | | | | | | | | | | | | Summary: Android has limits on file name lengths. This commit reduces the names of the test executables to satisfy these limits. Test Plan: dotest.py -p TestWatchpointMultipleThreads Reviewers: chaoren Reviewed By: chaoren Subscribers: tberghammer, lldb-commits Differential Revision: http://reviews.llvm.org/D9540 llvm-svn: 236783
* Make it so that changing formats on a synthetic value object causes children ↵Enrico Granata2015-05-071-0/+9
| | | | | | | | to be invalidated and refetched when needed This is required for supporting vector types formatting llvm-svn: 236769
* Revert "Enable TestConvenienceVariables on Linux"Pavel Labath2015-05-051-0/+1
| | | | | | | | This reverts commit 193ac6993b64a502db6dc7f2d69dafc47c318407. The buildbot says the test still fails. :) llvm-svn: 236500
* Enable TestConvenienceVariables on LinuxPavel Labath2015-05-051-1/+0
| | | | | | The test has passed in the last 300 runs for me, enabling to see what the buildbot says. llvm-svn: 236498
* Mark TestTypedefArray as XFAIL with Gcc.Oleksiy Vyalov2015-05-041-1/+2
| | | | llvm-svn: 236425
* un-skipped a bunch of tests on LinuxVince Harron2015-05-044-5/+10
| | | | | | | | | Some have been marked as skipIfLinux for years. The seem to be passing so I've enabled them. Differential Revision: http://reviews.llvm.org/D9428 llvm-svn: 236403
* Enabled libc++ formatter tests on LinuxVince Harron2015-05-0422-41/+88
| | | | | | | | | | Refactored TestInitializerList to not be an inline test. Refactored Makefiles to use USE_LIBCPP instead of adding FLAGS directly Fixed copy/paste error in TestDataFormatterUnordered class name Differenttial Revision: http://reviews.llvm.org/D9426 llvm-svn: 236401
OpenPOWER on IntegriCloud