summaryrefslogtreecommitdiffstats
path: root/lldb/test
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix StopHookForMultipleThreadsTestCase tests after r233098Ilia K2015-03-261-1/+1
| | | | llvm-svn: 233266
* Changed '-x'/'-xsize' to '-s'/'-size' when specifyingSean Callanan2015-03-263-13/+13
| | | | | | | | the size of a watchpoint. <rdar://problem/18184972> llvm-svn: 233237
* Add a test to make sure if you do:Greg Clayton2015-03-263-0/+104
| | | | | | | | | | | | % lldb /bin/echo (lldb) r 1 2 3 (lldb) r You get "1", "2", and "3" as arguments in the next re-run when no args are specified. This is behavior we do to match what GDB did and we need to test that we don't regress on it. <rdar://problem/20300941> llvm-svn: 233236
* Fix AVX register detectionTamas Berghammer2015-03-251-3/+3
| | | | | | * Use target triple instead of host platform llvm-svn: 233194
* Fix not_remote_testsuite_ready annotation in the test runnerTamas Berghammer2015-03-251-1/+1
| | | | | | Treat a test run as remote run also if lldb.remote_platform is set. llvm-svn: 233190
* Fix StdVBoolImplementation to handle large vectorsTamas Berghammer2015-03-251-1/+0
| | | | | | | | | | The previous implementation only read out the first element of the underlying storage array. Because of it only the first 32 (on x86) or the first 64 (on x86_64) element was displayed. Differential revision: http://reviews.llvm.org/D8585 llvm-svn: 233179
* xfail tests that failed with clang-3.7, gcc4.8.2 and on i386 to get buildbot ↵Ying Chen2015-03-2512-0/+14
| | | | | | | | | | | | | | | | | | green Summary: -Refer to bug https://buganizer.corp.google.com/issues/19893563 -Test log http://lab.llvm.org:8011/builders/lldb-x86_64-ubuntu-14.04-cmake/builds/1145 Test Plan: Run tests with different compiler and archs locally Reviewers: sivachandra, ovyalov, chaoren, vharron Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D8573 llvm-svn: 233157
* Add -gdb-show and target-async option in -gdb-show command (MI)Ilia K2015-03-241-0/+121
| | | | | | | | | | | | | | | | | | | | | Summary: This path adds -gdb-show command with 1 option: target-async. Also it adds tests for -gdb-set and -gdb-show commands. All tests pass on OS X. Test Plan: ./dotest.py -v --executable $BUILDDIR/bin/lldb -f MiGdbSetShowTestCase Reviewers: clayborg, abidh Reviewed By: clayborg, abidh Subscribers: lldb-commits, clayborg, abidh Differential Revision: http://reviews.llvm.org/D8566 llvm-svn: 233114
* Add support for CLI commands in lldb-miIlia K2015-03-241-0/+211
| | | | | | | | | | | | | | | | | | | Summary: This patch adds support for CLI command in lldb-mi. It's useful ability which also was implemented in gdb. All tests pass on OS X. Test Plan: ./dotest.py -v --executable $BUILDDIR/bin/lldb tools/lldb-mi/interpreter/ Reviewers: ted, clayborg, abidh Reviewed By: clayborg, abidh Subscribers: jingham, lldb-commits, ted, clayborg, abidh Differential Revision: http://reviews.llvm.org/D8483 llvm-svn: 233112
* [TestDataFormatterStdVector] s/-fstandalone-debug/-fno-limit-debug-infoSiva Chandra2015-03-241-3/+3
| | | | | | | | | | | | Test Plan: dotest.py -C <clang|gcc> -p TestDataFormatterStdVector Reviewers: vharron Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D8571 llvm-svn: 233108
* Fix error introduced by changing function signatures.Zachary Turner2015-03-243-1/+4
| | | | | | | | | | | | | | | | | Since ClangASTSource::layoutRecordType() was overriding a virtual function in the base, this was inadvertently causing a new method to be introduced rather than an override. To fix this all method signatures are changed back to taking DenseMaps, and the `override` keyword is added to make sure this type of error doesn't happen again. To keep the original fix intact, which is that fields and bases must be added in offset order, the ImportOffsetMap() function now copies the DenseMap into a vector and then sorts the vector on the value type (e.g. the offset) before iterating over the sorted vector and inserting the items. llvm-svn: 233099
* Fix record layout when synthesizing class types.Zachary Turner2015-03-243-4/+1
| | | | | | | | | | | | | | | | | Prior to this patch, we would try to synthesize class types by iterating over a DenseMap of FieldDecls and adding each one to a CXXRecordDecl. Since a DenseMap doesn't provide a deterministic ordering of the elements, this would not add the fields in FieldOffset order, but rather in some random order determined by the memory layout of the DenseMap. This patch fixes the issue by changing DenseMaps to vectors. The ability to lookup a value in the DenseMap was hardly being used, and where it is sufficient to do a vector lookup. Differential Revision: http://reviews.llvm.org/D8512 llvm-svn: 233090
* Skip SetSID test cases on remote platformTamas Berghammer2015-03-241-0/+6
| | | | | | | | | | On remote platform --setsid option is not used and currently it is also impossible to get the sid of an lldb-platform instance running on a remote target. Differential revision: http://reviews.llvm.org/D8317 llvm-svn: 233081
* Don't clobber CFLAGS_EXTRAS in tests.Robert Flack2015-03-2420-21/+21
| | | | | | | | | | | | | | | | | To run tests against a different target platform many extra compiler flags are needed to specify sysroot, include dirs, etc. The environment variable CFLAGS_EXTRAS seems suited for this purpose except that several Makefiles clobber the current flags. This change modifies all of these to add to CFLAGS_EXTRAS instead. Test Plan: Verify no regressions in ninja check-lldb. Run tests using CFLAGS_EXTRAS to specify cross compilation flags for a different target running lldb-server platform. Differential Revision: http://reviews.llvm.org/D8559 llvm-svn: 233066
* Rely on Makefile.rules in lldb/test/driver/batch_mode.Zachary Turner2015-03-231-26/+3
| | | | | | | | | | | This was hardcoding some make rules instead of relying on Makefile.rules, which was causing some of the logic to be incorrect for Windows. Patch by: Adrian McCarthy Differential Revision: http://reviews.llvm.org/D8363 llvm-svn: 232974
* Shorten executable name in WatchpointLLDBCommandTestCaseTamas Berghammer2015-03-231-1/+1
| | | | | | | It is required because the name of the executable exceeded the maximum allowed file name on android. llvm-svn: 232959
* Fix ObjCDataFormatterTestCase.test_nsdate_* tests (ver. 2)Ilia K2015-03-232-3/+3
| | | | | | This commit reverts r232946 because it caused an another error with absolute time. llvm-svn: 232951
* Fix ObjCDataFormatterTestCase.test_nsdate_* testsIlia K2015-03-231-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The time/date strings (like "6pm April 10, 1985") are interpreted as a local time but CFDateGetAbsoluteTime() returns time in UTC. It caused a problem when local time was UTC+0100 or more (0200, 0300 etc.): ``` ====================================================================== FAIL: test_nsdate_with_dsym_and_run_command (TestDataFormatterObjC.ObjCDataFormatterTestCase) Test formatters for NSDate. ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/IliaK/p/llvm/tools/lldb/test/lldbtest.py", line 462, in wrapper return func(self, *args, **kwargs) File "/Users/IliaK/p/llvm/tools/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py", line 157, in test_nsdate_with_dsym_and_run_command self.appkit_tester_impl(self.buildDsym,self.nsdate_data_formatter_commands) File "/Users/IliaK/p/llvm/tools/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py", line 34, in appkit_tester_impl commands() File "/Users/IliaK/p/llvm/tools/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py", line 475, in nsdate_data_formatter_commands substrs = ['1985-04','2011-01']) File "/Users/IliaK/p/llvm/tools/lldb/test/lldbtest.py", line 2146, in expect msg if msg else EXP_MSG(str, exe)) AssertionError: False is not True : '2011-01' returns expected result Config=x86_64-clang ====================================================================== FAIL: test_nsdate_with_dwarf_and_run_command (TestDataFormatterObjC.ObjCDataFormatterTestCase) Test formatters for NSDate. ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/IliaK/p/llvm/tools/lldb/test/lldbtest.py", line 479, in wrapper return func(self, *args, **kwargs) File "/Users/IliaK/p/llvm/tools/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py", line 163, in test_nsdate_with_dwarf_and_run_command self.appkit_tester_impl(self.buildDwarf,self.nsdate_data_formatter_commands) File "/Users/IliaK/p/llvm/tools/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py", line 34, in appkit_tester_impl commands() File "/Users/IliaK/p/llvm/tools/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py", line 475, in nsdate_data_formatter_commands substrs = ['1985-04','2011-01']) File "/Users/IliaK/p/llvm/tools/lldb/test/lldbtest.py", line 2146, in expect msg if msg else EXP_MSG(str, exe)) AssertionError: False is not True : '2011-01' returns expected result Config=x86_64-clang ``` llvm-svn: 232946
* Fix ninja check-lldbPavel Labath2015-03-201-1/+2
| | | | | | | | | | | | | Ninja apparently has issues with commands writing nul characters '\0' to stdout. When it encounters a nul character, the rest of the output is skipped (I will file a bug with ninja about that). This breaks the linux buildbot since it parses the ninja check-lldb output to get a list of failures. Recently, we have started outputting nul characters in lldb-server tests. This is probably a bug in itself, but I am not addressing that now. This is just a workaround commit, which prevents the nul characters from appearing in the output, and gets the buildbot operational again. llvm-svn: 232805
* Support for truncate/append on log filesPavel Labath2015-03-201-1/+52
| | | | | | | | | | | | | | | Summary: Presently, if a log file already exists, lldb simply starts overwriting bits of it, without truncating or anything. This patch makes it use eFileOptionFileTruncate by default. It also adds an --append option, which will append to the file without truncating. A test is included. Reviewers: clayborg Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D8450 llvm-svn: 232801
* Report watchpoint hits during single stepping.Chaoren Lin2015-03-193-0/+148
| | | | | | | | | | | | | | | | | | Summary: Reorganized NativeProcessLinux::MonitorSIGTRAP to check for watchpoint hits on TRAP_TRACE. Added test for stepping over watchpoints. https://llvm.org/bugs/show_bug.cgi?id=22814 Reviewers: ovyalov, tberghammer, vharron, clayborg Subscribers: jingham, labath, lldb-commits Differential Revision: http://reviews.llvm.org/D8404 llvm-svn: 232784
* expose 64 bit addresses through MIIlia K2015-03-191-1/+1
| | | | | | | | | | | | | | | | | Summary: This changes all reporting of addresses from lldb-mi to be 64 bit capable. There could have been cases where a 64 bit address was getting truncated to 32 bit format. Patch from chuckr@microsoft.com Reviewers: abidh, ChuckR Reviewed By: abidh Subscribers: paulmaybee, ki.stfu, zturner, lldb-commits Differential Revision: http://reviews.llvm.org/D8238 llvm-svn: 232736
* Fix -break-insert for system functions (MI)Ilia K2015-03-193-10/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: # Fix -break-insert for system functions # Fix MiExecTestCase to use -break-insert instead of CLI "b" # Improve MiBreakTestCase: now it uses printf() instead of in-house function All tests pass on OS X. Test Plan: ``` $ bin/lldb-mi --interpreter (gdb) -file-exec-and-symbols ~/p/hello ^done (gdb) =shlibs-added,shlib-info=[num="1",name="hello",dyld-addr="-",reason="dyld",path="/Users/IliaK/p/hello",loaded_addr="-",dsym-objpath="/Users/IliaK/p/hello.dSYM/Contents/Resources/DWARF/hello"] -break-insert -f printf ^done,bkpt={number="1",type="breakpoint",disp="keep",enabled="y",addr="0xffffffff",func="??",file="??",fullname="??/??",line="0",pending=["printf"],times="0",original-location="printf"} (gdb) =breakpoint-modified,bkpt={number="1",type="breakpoint",disp="keep",enabled="y",addr="0xffffffff",func="??",file="??",fullname="??/??",line="0",pending=["printf"],times="0",original-location="printf"} -exec-run ^running ... *stopped,reason="breakpoint-hit",disp="del",bkptno="1",frame={addr="0x7fff8a476910",func="printf",args=[],file="??",fullname="??",line="-1"},thread-id="1",stopped-threads="all" (gdb) ``` Reviewers: abidh, clayborg Reviewed By: clayborg Subscribers: lldb-commits, clayborg, abidh Differential Revision: http://reviews.llvm.org/D8412 llvm-svn: 232734
* Comment discouraging writing command based test cases.Jim Ingham2015-03-181-0/+24
| | | | llvm-svn: 232689
* Enable TestCallStdStringFunction for GCC.Siva Chandra2015-03-181-1/+0
| | | | | | | | | | | | Test Plan: dotest.py -C gcc -p TestCallStdStringFunction Reviewers: vharron Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D8426 llvm-svn: 232687
* Cleanup to simplify the formatter for std::map of libstdc++.Siva Chandra2015-03-181-2/+0
| | | | | | | | | | | | | | | | | | Summary: GCC does not emit some DWARF required for the simplified formatter to work. A workaround for it has been incorporated in the formatter. The corresponding test TestDataFormatterStdMap has also been enabled for GCC. Test Plan: dotest.py -C <clang|gcc> -p TestDataFormatterStdMap Reviewers: clayborg, vharron, granata.enrico Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D8424 llvm-svn: 232678
* Don't load register data from memory. Greg Clayton2015-03-181-1/+1
| | | | llvm-svn: 232668
* Always add some fake threads with x86_64 registers no matter what the ↵Greg Clayton2015-03-181-28/+24
| | | | | | architecture since this is just for testing that we can add new threads with completely different registers contexts to a process. llvm-svn: 232649
* Skip intermittently failing test on FreeBSDEd Maste2015-03-181-0/+1
| | | | | | | | It is already skipped on the other platforms anyhow. llvm.org/pr19246 llvm-svn: 232640
* Enable TestDataFormatterStdIterator with GCC.Siva Chandra2015-03-171-1/+0
| | | | | | | | | | | | | | | | | Summary: This test now passes for Clang and GCC. I do not know why it was disabled for GCC with link to a bug which should not have had an effect on this test. Test Plan: dotest.py -C gcc -p TestDataFormatterStdIterator Reviewers: vharron Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D8396 llvm-svn: 232552
* Implement formatter for std::vector<bool, ...> of libstdc++ in Python.Siva Chandra2015-03-171-5/+0
| | | | | | | | | | | | | | | | | | | Summary: The existing formatter in C++ has been removed as it was not being used. The associated test TestDataFormatterStdVBool.py has been enabled for both Clang and GCC on Linux. Test Plan: dotest.py -p TestDataFormatterStdVBool Reviewers: vharron, clayborg Reviewed By: clayborg Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D8390 llvm-svn: 232548
* Remove obsolate rdar comment from TestSetValues.pyTamas Berghammer2015-03-171-2/+0
| | | | llvm-svn: 232490
* XFAIL flaky testsVince Harron2015-03-172-0/+3
| | | | llvm-svn: 232441
* Enable TestDataFormatterStdMap on linux (libstdc++) with clang.Siva Chandra2015-03-162-4/+7
| | | | | | | | | | | | | | | | | | | | | Summary: This test should have been enabled along with 7181dae1248cc1b03505cca1b7c6e3dfeffefc0a, but since the test was actually crashing, I thought it was a much deeper problem. Turns out, all I had to do was to add "-fno-limit-debug-info" when compiling the test case. The test is still skipped when the testcase is compiled with GCC. Test Plan: dotest.py -p TestDataFormatterStdMap Reviewers: vharron Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D8364 llvm-svn: 232432
* Skip TestDataFormatterStdMap on linux instead of xfailing.Siva Chandra2015-03-161-4/+4
| | | | | | | | | | | | | | | | Summary: After 7181dae1248cc1b03505cca1b7c6e3dfeffefc0a, this test progresses much further but crashes. Will skip this test while I fix this properly. Test Plan: dotest.py -p TestDataFormatterStdMap Reviewers: vharron Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D8361 llvm-svn: 232403
* Added an Python operating system plug-in test to verify that python can be ↵Greg Clayton2015-03-164-0/+205
| | | | | | | | | | | | used to add threads to an existing process. The test does the following: 1 - runs a program to main without the OS plug-in and verifies no OS threads are in the process 2 - loads the OS plug-in and verifies the 3 OS plug-in threads are now in the current process 3 - verify the register contents of each thread that shows up 4 - unload the python OS plug-in and verify that the OS threads are gone. llvm-svn: 232401
* Handle PyLong return values in LLDBSwigPython_CalculateNumChildren.Siva Chandra2015-03-163-9/+7
| | | | | | | | | | | | | | | | | | | | | | Summary: Also, change its return type to size_t to match the return types of its callers. With this change, std::vector and std::list data formatter tests pass on Linux (when using libstdc++) with clang as well as with gcc. These tests have also been enabled in this patch. Test Plan: dotest.py -p <TestDataFormatterStdVector|TestDataFormatterStdList> Reviewers: vharron, clayborg Reviewed By: clayborg Subscribers: zturner, lldb-commits Differential Revision: http://reviews.llvm.org/D8337 llvm-svn: 232399
* Enabling the lldb-mi tests on Linux.Hafiz Abid Qadeer2015-03-165-24/+0
| | | | | | | | | I think the issue that caused the random failure has been fixed. So I am enabling the tests again on Linux. There are still some tests that are skipped on Linux due to different output. Those will be handled separately. Tested with dotest.py and with "make check-lldb" and there was no MI related failure. llvm-svn: 232380
* Fix the test for gcc.Hafiz Abid Qadeer2015-03-161-9/+9
| | | | | | | | | | | | | Following 3 changes were made. 1. Test was assuming that function name will have () in the end. I dont know why lldb is generating function name like this but it looks like a bug. For this test, I have removed it. 2. Step instruction test was assuming that function call will not be the first instruction in the range of the line. This assumption failed with gcc. So I had fixed this. 3. Some minor adjustments with the line number. Test with bot gcc and clang and all tests pass. This test is still very fragile. We should be removing hardcoded line number. llvm-svn: 232372
* Use -fno-limit-debug-info instead of -fstandalone-debug in testsVince Harron2015-03-1511-11/+11
| | | | | | | | | | | | | This fixes tests on clang-3.4 AFAICT, these flags have the same affect and -fstandalone-debug wasn't added until after clang-3.4 Committed to try to fix buildbot Differential Revision: http://reviews.llvm.org/D8347 llvm-svn: 232326
* Skip additional lldb-mi tests that failed on FreeBSDEd Maste2015-03-142-0/+3
| | | | llvm-svn: 232243
* Revert test/Makefile to state before r232205Vince Harron2015-03-131-294/+32
| | | | llvm-svn: 232227
* Add support for Python object commands to return custom short and long help ↵Enrico Granata2015-03-133-9/+12
| | | | | | | | | | | | | by implementing def get_short_help(self) def get_long_help(self) methods on the command object Also, add a test case for this feature llvm-svn: 232224
* Fix makefiles to build shared library tests on Windows.Zachary Turner2015-03-136-23/+51
| | | | | | | | | | | | | | | Abstracted away some POSIX-isms that caused MAKE to issue invalid commands on Windows. Added a new force-include for the test programs so that we can use platform-specific macros. TestSharedLib now builds and cleans up on Windows, though the test still fails some of the expectations. Differential Revision: http://reviews.llvm.org/D8277 Patch by: Adrian McCarthy Issue Tracker: http://llvm.org/pr21727 llvm-svn: 232220
* Add support for XFAILing a test on specific clang versionsVince Harron2015-03-132-34/+298
| | | | llvm-svn: 232205
* Make TestSBFrameFindValue compatible with remote targetsTamas Berghammer2015-03-131-1/+1
| | | | llvm-svn: 232171
* Forward adb port for reverse connect test casesTamas Berghammer2015-03-132-5/+12
| | | | | | | | | | | The test cases in TestStubReverseConnect are using a socket connection from python to lldb-server running on a remote target. To enable the socket connection an adb port forwarding have to be set up when the remote target is android. Differential revision: http://reviews.llvm.org/D8319 llvm-svn: 232170
* Skip VectorTypesFormatting test case when using gccTamas Berghammer2015-03-131-0/+1
| | | | | | Gcc don't support the ext_vector_type extension used by the test llvm-svn: 232169
* Fix expectation in TestDataFormatterSynthTamas Berghammer2015-03-131-1/+1
| | | | | | | | | The value of some_values (pointer) expeced to start by 0x0 but nothing requires that the first digit of the address be '0'. This CL change the expectation to check only for a value starting with 0x. llvm-svn: 232163
* Create NativeRegisterContext for android-arm64Tamas Berghammer2015-03-131-0/+4
| | | | | | Differential revision: http://reviews.llvm.org/D8058 llvm-svn: 232160
OpenPOWER on IntegriCloud