summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test
Commit message (Collapse)AuthorAgeFilesLines
...
* Complete complete types early when importing types from Clang module DWARF.Adrian Prantl2019-11-226-0/+95
| | | | | | | | | | | | | | | | | | | | | This affects -gmodules only. Under normal operation pcm_type is a shallow forward declaration that gets completed later. This is necessary to support cyclic data structures. If, however, pcm_type is already complete (for example, because it was loaded for a different target before), the definition needs to be imported right away, too. Type::ResolveClangType() effectively ignores the ResolveState inside type_sp and only looks at IsDefined(), so it never calls ClangASTImporter::ASTImporterDelegate::ImportDefinitionTo(), which does extra work for Objective-C classes. This would result in only the forward declaration to be visible. An alternative implementation would be to sink this into Type::ResolveClangType ( https://github.com/llvm/llvm-project/blob/88235812a71d99c082e7aa2ef9356d43d1f83a80/lldb/source/Symbol/Type.cpp#L5809) though it isn't clear to me how to best do this from a layering perspective. rdar://problem/52134074 Differential Revision: https://reviews.llvm.org/D70415
* [lldb] Fix exception breakpoint not being resolved when set on dummy targetMartin Svensson2019-11-221-0/+35
| | | | | | | | | | | | | | Summary: Ensure that breakpoint ivar is properly set in exception breakpoint resolver so that exception breakpoints set on dummy targets are resolved once real targets are created and run. Reviewers: jingham Reviewed By: jingham Subscribers: teemperor, JDevlieghere, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D69880
* [lldb] Don't enable expression log in TestEmptyStdModule.pyRaphael Isemann2019-11-221-1/+0
| | | | Thanks for pointing this out Jason!
* [test] Mark TestEditline as skipped with ASan.Jonas Devlieghere2019-11-211-0/+1
| | | | As discussed in https://reviews.llvm.org/D70324.
* [Test] Split up TestIntegerTypes.pyJonas Devlieghere2019-11-2110-217/+297
| | | | | The unsplit test is timing out on GreenDragon's sanitized bot. By splitting the test we avoid this issue and increase parallelism.
* [lldb][NFC] Remove test directory completelyTatyana Krasnukha2019-11-213-2/+0
| | | | | | The test was moved to "completion-in-lambda-and-unnamed-class" by D66175. + Fix typo in the directory name.
* Handle the case where the 'g' packet doesn't get all regs.Jason Molenda2019-11-202-1/+199
| | | | | | | | | | lldb would silently accept a response to the 'g' packet (read all registers) which was too large; this handles the case where it is too small. Differential Revision: https://reviews.llvm.org/D70417 <rdar://problem/34916465>
* [lldb] [test] Un-XFAIL one lldb-server test on NetBSDMichał Górny2019-11-201-1/+0
|
* Reland "[clang] Remove the DIFlagArgumentNotModified debug info flag"Djordje Todorovic2019-11-201-1/+2
| | | | | | | | | | It turns out that the ExprMutationAnalyzer can be very slow when AST gets huge in some cases. The idea is to move this analysis to the LLVM back-end level (more precisely, in the LiveDebugValues pass). The new approach will remove the performance regression, simplify the implementation and give us front-end independent implementation. Differential Revision: https://reviews.llvm.org/D68206
* [lldb][test] Prevent \n in calls to lldb's expect() test helper.Jordan Rupprecht2019-11-192-17/+15
| | | | | | | | | | | | | | | | | Summary: expect() forwards its command to sendline(). This can be problematic if the command already contains a newline: sendline() unconditionally adds a newline to the command, which causes the command to run twice (hitting enter in lldb runs the previous command). The expect() helper looks for the prompt and finds the first one, but because the command has run a second time, the buffer will contain the contents of the second time the command ran, causing potential erroneous matching. Simplify the editline test, which was using different commands to workaround this misunderstanding. Reviewers: labath Reviewed By: labath Subscribers: merge_guards_bot, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D70324
* [lldb] Also test Get[De]mangledName of SBType in TestSBTypeClassMembers.pyRaphael Isemann2019-11-191-0/+14
| | | | | | I just used the mangled names as this test is anyway a Darwin-only ObjC++ test. We probably should also test this on other platforms but that will be another commit as we need to untangle the ObjC and C++ parts first.
* Mark PR44037 tests as XFAIL on AArch64 Linux dwoDiana Picus2019-11-194-1/+24
| | | | | | | | | | | | These tests are failing with various assertion failures, but they all throw the following error message first: error: a.out 0x0000002d: adding range [0x14-0x24) which has a base that is less than the function's low PC 0x40060c. See llvm.org/pr44037. Differential Revision: https://reviews.llvm.org/D70381
* [lldb] [test] XFAIL more lldb-server tests on NetBSDMichał Górny2019-11-181-0/+11
|
* [lldb] [test] Mark segv-related tests XFAIL on NetBSDMichał Górny2019-11-183-0/+3
| | | | | There seems to be a regression in the kernel causing those tests to fail. Mark them XFAIL, to be addressed later.
* [lldb] [Process/NetBSD] Implement thread name gettingMichał Górny2019-11-182-2/+1
| | | | | | | Implement thread name getting sysctl() on NetBSD. Also fix the incorrect type in pthread_setname_np() in the relevant test. Differential Revision: https://reviews.llvm.org/D70363
* [lldb] [test] Enable lldb-server tests on NetBSD, and set XFAILsMichał Górny2019-11-1811-2/+28
| | | | Differential Revision: https://reviews.llvm.org/D70335
* Remove +x permission on some filesSylvestre Ledru2019-11-161-0/+0
|
* [lldb-vscode] support the completion requestWalter Erquinigo2019-11-156-2/+154
| | | | | | | | | | | | | | | | Summary: The DAP has a completion request that has been unimplemented. It allows showing autocompletion tokens inside the Debug Console. I implemented it in a very simple fashion mimicking what the user would see when autocompleting an expression inside the CLI. There are two cases: normal variables and commands. The latter occurs when a text is prepepended with ` in the Debug Console. These two cases work well and have tests. Reviewers: clayborg, aadsm Subscribers: lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D69873
* Add a testcase for Clang modules being updated within one LLDB session.Adrian Prantl2019-11-156-0/+87
| | | | This actually works as expected, but wasn't explicitly tested before.
* dotest: Add a way for the run_to_* helpers to register dylibsFred Riss2019-11-152-12/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: To run the testsuite remotely the executable needs to be uploaded to the target system. The Target takes care of this by default. When the test uses additional shared libraries, those won't be handled by default and need to be registered with the target using test.registerSharedLibrariesWithTarget(target, dylib). Calling this API requires a target, so it doesn't mesh well with the run_to_* helpers that we've been advertising as the right way to write tests. This patch adds an extra_images argument to all the helpers and does the registration automatically when running a remote testsuite. TestWeakSymbols.py was converted to use this new scheme. Reviewers: jingham Subscribers: lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D70134
* [-gmodules] Let LLDB log a warning if the Clang module hash mismatches.Adrian Prantl2019-11-155-1/+83
| | | | | | | | This feature is mostly there to aid debugging of Clang module issues, since the only useful actual the end-user can to is to recompile their program. Differential Revision: https://reviews.llvm.org/D70272
* Fix TestFormatters.py stepping too farDiana Picus2019-11-152-6/+5
| | | | | | | | | | | | | TestFormatters.py has a sequence of three 'next' commands to get past all the initializations in the test function. On AArch64 (and potentially other platforms), this was one 'next' too many and we ended up outside our frame. This patch replaces the sequence with a 'thread until ' the line of the return from the function, so we should stop after all the initializations but before actually returning. Differential Revision: https://reviews.llvm.org/D70303
* [lldb][Editline] Support ctrl+left/right arrow word navigation.Jordan Rupprecht2019-11-141-0/+49
| | | | | | | | | | | | | | | | | Summary: This adds several 5C/5D escape codes that allow moving forward/backward words similar to bash command line navigation. On my terminal, `ctrl+v ctrl+<left arrow>` prints `^[[1;5D`. However, it seems inputrc also maps other escape variants of this to forward/backward word, so I've included those too. Similar for 5C = ctrl+right arrow. Reviewers: JDevlieghere, labath Reviewed By: JDevlieghere, labath Subscribers: merge_guards_bot, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D70137
* [LLDB] Fix whitespace/tabs mismatch in lldbsuite Makefile.rulesMuhammad Omair Javaid2019-11-141-34/+34
| | | | | | | | | | | | This patch fixes whitespace/tabs mismatch in lldb/packages/Python/lldbsuite/test/make/Makefile.rules Legacy make files always used tabs though modern make version can work with white-spaces I have chosen the legacy just to be safe. Signed-off-by: Muhammad Omair Javaid <omair.javaid@linaro.org> Differential Revision: https://reviews.llvm.org/D70154
* [LLDB] Add core definition for armv8l and armv7lMuhammad Omair Javaid2019-11-132-2/+2
| | | | | | | | | | | | | This patch adds core definitions in lldb ArchSpecs for armv8l and armv7l cores. This was needed because on Linux running on 32-bit Arm v8 we are returned armv8l in case we are running 32-bit sysroot on 64bit kernel. In case of 32-bit kernel and 32-bit sysroot running on arm v8 hardware we are returned armv7l. This is quite common when we run 32 bit arm using docker container. Signed-off-by: Muhammad Omair Javaid <omair.javaid@linaro.org> Differential Revision: https://reviews.llvm.org/D69904
* [LLDB][Formatters] Re-enable std::function formatter with fixes to improve ↵shafik2019-11-123-15/+19
| | | | | | | | | non-cached lookup performance Performance issues lead to the libc++ std::function formatter to be disabled. We addressed some of those performance issues by adding caching see D67111 This PR fixes the first lookup performance by not using FindSymbolsMatchingRegExAndType(...) and instead finding the compilation unit the std::function wrapped callable should be in and then searching for the callable directly in the CU. Differential Revision: https://reviews.llvm.org/D69913
* [lldb][test] Macros in expressions require DWARF 5Tatyana Krasnukha2019-11-122-1/+4
|
* [lldb] Re-enable VSCode testsJonas Devlieghere2019-11-118-24/+3
| | | | | | | The VSCode tests were all disabled on macOS because the implementation had some issues that resulted in flakiness on Darwin. It seems most of these issues have been addressed. I've re-enabled all the tests that consistently passed locally.
* Replace tabs with spaces. (NFC)Adrian Prantl2019-11-111-11/+11
|
* Fix a regression in macOS-style path remapping.Adrian Prantl2019-11-114-6/+21
| | | | | | | | | | | | | | | | When we switched to the LLVM .debug_line parser, the .dSYM-style path remapping logic stopped working for relative paths because of how RemapSourceFile silently fails for relative paths. This patch both makes the code more readable and fixes this particular bug. One interesting thing I learned is that Module::RemapSourceFile() is a macOS-only code path that operates on on the lldb::Module level and is completely separate from target.source-map, which operates on a per-Target level. Differential Revision: https://reviews.llvm.org/D70037 rdar://problem/56924558
* Add a testcase for .dSYM path remapping dictionaries.Adrian Prantl2019-11-113-0/+69
| | | | rdar://problem/56924558
* Fix TestNoGPacketSupported on linuxPavel Labath2019-11-111-2/+2
| | | | | | | | The mock server pretends the process stopped with signal 17, which is SIGCHLD on linux. This causes lldb to resume to process, utterly confusing the test. Lldb probably shouldn't resume in this case, but for now this issue can be fixed by changing the signal number to 2, which is SIGINT just about anywhere.
* [lldb] [test] Fix typo in TestSendSignalMichał Górny2019-11-111-1/+1
|
* [lldb] [test] Mark TestSendSignal XFAIL on NetBSDMichał Górny2019-11-111-0/+1
|
* [lldb] [test] Un-XFAIL tests that work on NetBSD 9Michał Górny2019-11-094-6/+0
|
* Temporarily change the default for use-g-packet-for-reading to false,Jason Molenda2019-11-082-1/+4
| | | | | | | | until we can automatically fall back to p/P if g/G are not supported; it looks like there is a bug in debugserver's g/G packets taht needs to be fixed, or debugserver should stop supporting g/G until that bug is fixed. But we need lldb to be able to fall back to p/P correctly for that to be a viable workaround.
* Revert "Add a testcase for .dSYM path remapping dictionaries."Jonas Devlieghere2019-11-083-69/+0
| | | | This reverts commit 2bbc4fdd8fa0ed58d610ab6260cb664c7cfef204.
* Test case to verify that lldb falls back to p/P if g is unsupportedJason Molenda2019-11-081-0/+98
| | | | | | | | | and that lldb uses the expedited register values in the ? packet aka stop packet (T11 etc) and does not re-fetch them with the p packet. This test is currently failing from the "[lldb-server] Add setting to force 'g' packet use" commit; I'm marking it as @expectedFailureAll until we can get this fixed.
* Add a testcase for .dSYM path remapping dictionaries.Adrian Prantl2019-11-083-0/+69
| | | | rdar://problem/56924558
* [lldb] Skip parts of TestCallOverriddenMethod.py on LinuxRaphael Isemann2019-11-081-4/+18
| | | | | | The function call and the constructor call fail now several Linux bots (Swift CI, my own bot and Stella's Debian system), so let's disable the relevant test parts until we can figure out why it is failing.
* Modernize TestWeakSymbols MakefileFred Riss2019-11-071-20/+15
|
* [lldb] Add -m option to 'target modules dump symtab' to disable demanglingRaphael Isemann2019-11-072-0/+48
| | | | | | | | | | | | | | Summary: This option was added downstream in swift-lldb. This upstreams this option as it seems useful and also adds the missing tests. Reviewers: #lldb, kwk, labath Reviewed By: kwk, labath Subscribers: labath, kwk, abidh, JDevlieghere, lldb-commits Tags: #lldb, #upstreaming_lldb_s_downstream_patches Differential Revision: https://reviews.llvm.org/D69944
* [lldb-server] Add setting to force 'g' packet useGuilherme Andrade2019-11-072-1/+85
| | | | | | | | | | | | Following up on https://reviews.llvm.org/D62221, this change introduces the settings plugin.process.gdb-remote.use-g-packet-for-reading. When they are on, 'g' packets are used for reading registers. Using 'g' packets can improve performance by reducing the number of packets exchanged between client and server when a large number of registers needs to be fetched. Differential revision: https://reviews.llvm.org/D62931
* [LLDB] Adding caching to libc++ std::function formatter for lookups that ↵shafik2019-11-062-13/+49
| | | | | | | | | | require scanning symbols Performance issues lead to the libc++ std::function formatter to be disabled. This change is the first of two changes that should address the performance issues and allow us to enable the formatter again. In some cases we end up scanning the symbol table for the callable wrapped by std::function for those cases we will now cache the results and used the cache in subsequent look-ups. This still leaves a large cost for the initial lookup which will be addressed in the next change. Differential Revision: https://reviews.llvm.org/D67111
* [test] Fix apple_simulator_test decorator when simulators are unavailableAlex Langford2019-11-061-1/+1
| | | | | In the case where xcodebuild fails as you set up simulator tests, you would fail because `feature` is never defined.
* Testuite: Support Asan test with remote testingFred Riss2019-11-063-8/+18
| | | | | | To do so, we need to register the sanitizer libraries with the target so that they get uploaded before running. This patch adds a helper to the test class to this effect.
* [TestMTCSimple] Disable the test if you don't have libMTCAlex Langford2019-11-051-1/+5
| | | | | | If you are running on macOS and have the CommandLineTools installed of Xcode, this test will fail because CommandLineTools doesn't ship with libMainThreadChecker. Skip the test if you don't have it installed.
* TestBatchMode.py: add missing @skipIfRemoteFred Riss2019-11-051-0/+1
| | | | | All the tests in this file were already marked as skipped for remote tests except for this one.
* testsuite: skipIfNoSBHeaders should skip when running remotelyFred Riss2019-11-051-0/+3
| | | | | The LLDB dylib/framework will not be available on the remote host, it makes no sense to try to run those tests in a remote scenario.
* Modernize add-dsym test MakefileFred Riss2019-11-051-17/+7
|
OpenPOWER on IntegriCloud