summaryrefslogtreecommitdiffstats
path: root/lldb/test
Commit message (Collapse)AuthorAgeFilesLines
...
* Update Makefile to reflect that TestNumThreads now uses std::thread instead ↵Adrian McCarthy2015-05-211-1/+1
| | | | | | of pthreads. llvm-svn: 237919
* Add bug number for TestEventsTamas Berghammer2015-05-211-1/+1
| | | | llvm-svn: 237904
* XFAIL TestEvents on Linux bacuse it is flakyTamas Berghammer2015-05-211-0/+1
| | | | llvm-svn: 237888
* 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
* trivial log print fixVince Harron2015-05-211-1/+1
| | | | llvm-svn: 237878
* Using -pthread instead of -lpthread to appease GCC.Chaoren Lin2015-05-211-1/+1
| | | | llvm-svn: 237864
* Have TestNumThreads use std::thread instead of pthreads so that it can work ↵Adrian McCarthy2015-05-204-62/+57
| | | | | | cross-platform. llvm-svn: 237844
* Fix handling of hijacked events in synchronous modeIlia K2015-05-201-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch includes the following changes: * Fix Target::Launch to handle hijacked event in synchronous mode * Improve MiStartupOptionsTestCase tests to expect *stopped (MI) * Add SBProcess::GetStopEventForStopID * Add ProcessModID::SetStopEventForLastNaturalStopID/GetStopEventForStopID * Add const qualifier to ProcessModID::GetLastNaturalStopID * Add SBProcess::GetStopEventForStopID * Don't broadcast hijacked event in Target::Launch * Add CMICmnLLDBDebugger::CheckIfNeedToRebroadcastStopEvent/RebroadcastStopEvent Test Plan: ./dotest.py -v --executable $BUILDDIR/bin/lldb tools/lldb-mi/startup_options/ Reviewers: zturner, jingham, clayborg, abidh Reviewed By: clayborg Subscribers: abidh, zturner, lldb-commits, clayborg, jingham Differential Revision: http://reviews.llvm.org/D9371 llvm-svn: 237781
* Mark TestEvents as XTIMEOUT on LinuxTamas Berghammer2015-05-191-0/+1
| | | | llvm-svn: 237679
* Don't print =breakpoint-created if BP info was emitted in the result record (MI)Ilia K2015-05-193-7/+11
| | | | llvm-svn: 237676
* dotest - minor doc fixVince Harron2015-05-191-2/+2
| | | | llvm-svn: 237665
* Make it possible to run dotest on Linux without any parametersVince Harron2015-05-181-5/+15
| | | | | | | | | | | | dotest will select clang-3.5 by default and fall back on clang/gcc dotest will look for the lldb executable in the typical cmake output locations: {lldb}/../../../build/bin (next to llvm directory) {lldb}/../../../build/host/bin (next to llvm directory) {lldb}/../build/bin (next to lldb directory) {lldb}/../build/host/bin (next to lldb directory) llvm-svn: 237632
* Fixes errors in remote testsVince Harron2015-05-181-1/+1
| | | | llvm-svn: 237603
* Refactored dotest arg parser so that it's accessible from dosepVince Harron2015-05-183-119/+132
| | | | | | | | This allows dosep to understand an act on dotest arguments Differential Revision: http://reviews.llvm.org/D9820 llvm-svn: 237602
* dotest - Refactored some code into loopsVince Harron2015-05-181-85/+72
| | | | | | | | | | | Renamed 'base' to 'lldbRootDirectory' Renamed 'lldbPath' to 'lldbPythonDir' Added cmake output directories to lldb executable search locations Fixed invocation of lldb -P to ignore 'Cannot read termcap database' Differential Revision: http://reviews.llvm.org/D9818 llvm-svn: 237601
* Refactored lldb executable name discoveryVince Harron2015-05-1824-118/+92
| | | | | | | | | | | | | | | | | | | | 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
* XTIMEOUT TestThreadSpecificBreakpoint.py on darwinVince Harron2015-05-181-0/+4
| | | | | | Differential Revision: http://reviews.llvm.org/D9815 llvm-svn: 237599
* 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
* Fix typo in previous commitPavel Labath2015-05-181-1/+1
| | | | llvm-svn: 237575
* Update TestMiVar with a bug idPavel Labath2015-05-181-1/+1
| | | | llvm-svn: 237571
* Add --move-to-nearest-code / target.move-to-nearest-code options (attempt 2)Ilia K2015-05-1814-15/+154
| | | | | | | | | | | | 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 flakey tests on DarwinVince Harron2015-05-174-0/+4
| | | | llvm-svn: 237543
* XFAIL'd some tests that fail very, very rarelyVince Harron2015-05-163-0/+3
| | | | llvm-svn: 237515
* Constant result ValueObjects are - well - constantEnrico Granata2015-05-163-0/+73
| | | | | | | | | | And they also do not have a thread/frame attached to them That makes dynamic and synthetic values attached to them impossible to update - which, among other things, makes it impossible to properly display persistent variables of types that could have such dynamic/persistent values Fix this by making it so that a ValueObject can control its constantness (hint: dynamic and synthetic values cannot be constant) and whether it wants to let itself be updated when an invalid thread is around llvm-svn: 237504
* XFAIL'd MiVarTestCase.test_lldbmi_eval on gcc-4.9/i386Vince Harron2015-05-151-0/+1
| | | | | | | | It times out on TestMyVar:113 self.expect("\^done,value=\"0x[0-9a-f]+\"") llvm-svn: 237480
* Reverting r237460 to fix test failures introduced on OSX & LinuxVince Harron2015-05-1510-150/+11
| | | | | | | | | TestExitDuringStep.py TestNumThreads.py TestThreadExit.py TestThreadStates.py llvm-svn: 237479
* Choose stdlib for test suite based on target platform.Robert Flack2015-05-151-7/+7
| | | | | | | | | | | | | | When compiling programs for the test suite we currently choose which stdlib to use based on the host platform, but should be basing this on the target platform. Test Plan: ./dotest.py $DOTEST_OPTS -t -p TestThreadExit.py This test previously failed mac->linux most of the time due to using the mac host's atomic declaration. Differential Revision: http://reviews.llvm.org/D9797 llvm-svn: 237466
* Add --move-to-nearest-code / target.move-to-nearest-code optionsIlia K2015-05-1510-11/+150
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Improve the MiVarTestCase.test_lldbmi_var_list_children test (MI)Ilia K2015-05-152-6/+32
| | | | llvm-svn: 237454
* Skip TestPluginCommands.py if host lldb library is incompatible with remote.Robert Flack2015-05-152-2/+36
| | | | | | | | | | | | | | | 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
* Fix CMICmdArgValPrintValues::Validate & enable 4 tests that were XFAIL'ed in ↵Ilia K2015-05-152-4/+0
| | | | | | r237437 (MI) llvm-svn: 237443
* XFAIL 4 lldb-mi tests to get Linux build green back (MI)Ilia K2015-05-152-0/+4
| | | | llvm-svn: 237437
* Fix parsing of print-values arg (MI)Ilia K2015-05-152-18/+9
| | | | | | | | | # Add CMICmdArgValPrintValues argument # Rework -stack-list-arguments/-stack-list-locals/-stack-list-variables/-var-update/-var-list-children commands to use the CMICmdArgValPrintValues argument instead of usage of pair of non-mandatory arguments like: CMICmdArgValNumber(0) || CMICmdArgValLongOptions("no-values") llvm-svn: 237429
* Fix a reason of *stopped notifications due to SIGINT/SIGSTOP signals (MI)Ilia K2015-05-151-3/+3
| | | | | | | | | | | | | # Add SBProcess::GetInterruptedFromEvent # Add vrEvent arg in CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStateStopped and CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStopSignal # Refactor CMICmnLLDBDebuggerHandleEvents::HandleProcessEventStopSignal ## Clean up and fix typos ## Remove vwrbShouldBrk arg # Fix MiSignalTestCase.test_lldbmi_stopped_when_stopatentry_{local,remote} to expect SIGSTOP instead of SIGINT llvm-svn: 237426
* 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
* XTIMEOUT tests timing out on the FreeBSD buildbotEd Maste2015-05-141-0/+5
| | | | llvm-svn: 237369
* [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
* Added XTIMEOUT for TestAttachDenied.pyVince Harron2015-05-131-0/+1
| | | | llvm-svn: 237319
* Don't import lock on Windows.Zachary Turner2015-05-131-1/+1
| | | | | | | | lock imports fcntl, which doesn't exist on Windows. If we need to use this class on Windows, we will need to implement something based on the CreateMutex API. llvm-svn: 237292
* Fix broken test, this wasn't supposed to get committed.Zachary Turner2015-05-131-6/+0
| | | | llvm-svn: 237291
* Select expected remote libc++ library name based on remote platform.Robert Flack2015-05-131-1/+1
| | | | | | | | | | | | | | | | | | Select expected remote libc++ library name based on remote platform. This is used to verify libc++ is in the loaded image list by various tests which use it. Test Plan: Passes the following tests mac -> linux with this patch: TestDataFormatterLibccIterator.py TestDataFormatterLibccMap.py TestDataFormatterLibccMultiMap.py TestDataFormatterLibcxxMultiSet.py TestDataFormatterLibcxxSet.py TestDataFormatterUnordered.py Differential Revision: http://reviews.llvm.org/D9759 llvm-svn: 237288
* 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
* Darwin - fix intermitent crashes in import crashinfoVince Harron2015-05-132-3/+39
| | | | | | | | | | | | | | | | Summary: "import crashinfo" was probably failing because multiple dotest invocations are all trying to compile crashinfo.so at the same time. I've put a mutex around the compile step to prevent this. Reviewers: clayborg, chying Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D9732 llvm-svn: 237230
* dosep can run tests in a specific subfolderVince Harron2015-05-121-7/+16
| | | | | | | | | | For example: ./dosep.py -o "$DOTEST_OPTS" lang/c/ Differential Revision: http://reviews.llvm.org/D9724 llvm-svn: 237207
OpenPOWER on IntegriCloud