summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/functionalities
Commit message (Collapse)AuthorAgeFilesLines
* Get register context for the 32-bit process in a WoW64 process minidumpAdrian McCarthy2016-02-253-0/+107
| | | | | | | | | | | | 32-bit processes on 64-bit Windows run in a layer called WoW64 (Windows-on-Windows64). If you capture a mini dump of such a process from a 32-bit debugger, you end up with a register context for the 64-bit WoW64 process rather than the 32-bit one you probably care about. This detects WoW64 by looking to see if there's a module named wow64.dll loaded. For such processes, it then looks in the 64-bit Thread Environment Block (TEB) to locate a copy of the 32-bit CONTEXT record that the plugin needs for the register context. Added some rudimentary tests. I'd like to improve these later once we figure out how to get the exception information from these mini dumps. Differential Revision: http://reviews.llvm.org/D17465 llvm-svn: 261808
* xfail case sensitivity test on Linux.Zachary Turner2016-02-241-0/+1
| | | | | | | | | | | | There are two tests in this file. One which only runs on Windows and tests that you can set a breakpoint with mismatched case. And another that only runs on non-Windows and tests that you cannot set a breakpoint with mismatched case. This latter test is failing on non Windows platforms for some reason. It could be that the test is just written incorrectly, as I think the actual functionality actually works correctly on non-Windows platforms. llvm-svn: 261800
* Some fixes for case insensitive paths on Windows.Zachary Turner2016-02-243-0/+134
| | | | | | | | | | | | | | | | | | | Paths on Windows are not case-sensitive. Because of this, if a file is called main.cpp, you should be able to set a breakpoint on it by using the name Main.cpp. In an ideal world, you could just tell people to match the case, but in practice this can be a real problem as it requires you to know whether the person who compiled the program ran "clang++ main.cpp" or "clang++ Main.cpp", both of which would work, regardless of what the file was actually called. This fixes http://llvm.org/pr22667 Patch by Petr Hons Differential Revision: http://reviews.llvm.org/D17492 Reviewed by: zturner llvm-svn: 261771
* Remove expectedFailureFreeBSD decoratorEd Maste2016-02-1910-14/+14
| | | | | | | | All invocations are updated to use the generic expectedFailureAll. Differential Revision: http://reviews.llvm.org/D17455 llvm-svn: 261355
* Remove XFAIL from test passing on FreeBSDEd Maste2016-02-191-1/+0
| | | | | | | | | | | There is a report in the PR from several months ago that it failed intermittently, but it is passing consistently for me on FreeBSD 10 and 11. We can re-add a decorator if further testing shows it is still flakey. llvm.org/pr17214 llvm-svn: 261340
* Remove XFAIL from test passing on FreeBSDEd Maste2016-02-191-1/+0
| | | | | | | | This is passing for me consistently on FreeBSD 10 and FreeBSD 11. llvm.org/pr15989 llvm-svn: 261339
* Remove expectedFlakeyFreeBSD decorator for prompt settingEd Maste2016-02-181-1/+0
| | | | | | | | | The race condition/use after free involved in setting long prompts appears to be fixed now (although I do not know which commit fixed it). llvm.org/pr22611 llvm-svn: 261266
* Add target and host platform enumerations so we're not using strings.Zachary Turner2016-02-182-2/+4
| | | | | | Differential Revision: http://reviews.llvm.org/D17088 llvm-svn: 261241
* Bump up timeout in TestChangeProcessGroupPavel Labath2016-02-161-1/+1
| | | | | | | The test fails very rarely. I suspect this is simply because the inferior does not have enough time to create the file under heavy load. llvm-svn: 260951
* [TestLibCxxAtomic] Skip for GCC.Siva Chandra2016-02-131-0/+1
| | | | | | | | | | | | Summary: This is the form on other libc++ tests. Reviewers: sivachandra Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D17230 llvm-svn: 260793
* [TestLibCxxAtomic] Fix Makefile so that the test builds on Linux.Siva Chandra2016-02-131-0/+1
| | | | | | | | | | Reviewers: granata.enrico Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D17227 llvm-svn: 260770
* Data formatter support for libc++ std::atomic<T>Enrico Granata2016-02-123-0/+81
| | | | | | | | | | On libc++ std::atomic is a fairly simple data type (layout wise, at least), wrapping actual contents in a member variable named "__a_" All the formatters are doing is "peel away" this intermediate layer and exposing user data as direct children or values of the std::atomic root variable Fixes rdar://24329405 llvm-svn: 260752
* The data formatters for NSArray, NSDictionary and (only partially) NSSet ↵Enrico Granata2016-02-124-64/+1
| | | | | | | | | | | | | | | | | contain logic to inspect the objects without running code. However, they also contain fallback logic that - in cases where LLDB can't recognize the specific subclass - actually does run code in order to inspect those objects. The argument for this logic was that these data types are critical enough that the risk of getting it wrong is outweighed by the advantage of always providing accurate child information. Practical experience however shows that "po" - a code running data-inspection command - is quite frequently used, and not considered burdensome by users. As such, this makes the code-running fallback in the data formatters a risk that carries very little actual reward. Also, unlike the time this code was originally written, we now have accurate class information for Objective-C, and thus we are less likely to improperly identify classes. This commit removes support for the code-running fallback, and aligns the data formatters for NSArray, NSDictionary and NSSet to the general no-code-running behavior of other data formatters. While it is possible for us to add support for some subclasses that are now no longer covered by static inspection alone, this is beyond the scope of this commit. llvm-svn: 260664
* When calling TypeSystemMap::Clear, objects being destroyed in the process of Jim Ingham2016-02-121-17/+16
| | | | | | | | | | | | | | | | | clearing the map ended up calling back into the TypeSystemMap to do lookups. Not a good idea, and in this case it would cause a deadlock. You would only see this when replacing the target contents after an exec, and only if you had stopped before the exec, evaluated an expression, then continued on to the point where you did the exec. Fixed this by making sure the TypeSystemMap::Clear tears down the TypeSystems in the map before clearing the map. I also add an expression before exec to the TestExec.py so that we'll catch this issue if it crops up again in the future. <rdar://problem/24554920> llvm-svn: 260624
* XFAIL TestCommandScriptImmediateOutput on FreeBSD alsoEd Maste2016-02-111-1/+1
| | | | llvm-svn: 260589
* Remove expectedFailureLinux decorator.Zachary Turner2016-02-1017-48/+46
| | | | llvm-svn: 260422
* [LLDB][MIPS] Generalise MIPS arch namesMohit K. Bhakkad2016-02-103-3/+3
| | | | | | | | | | Patch by Nitesh Jain Reviewers: clayborg, jaydeep. Subscribers: zturner, bhushan, mohit.bhakkad, sagar, lldb-commits. Differential Revision: http://reviews.llvm.org/D16840 llvm-svn: 260362
* Remove skipIf<compiler> decorators.Zachary Turner2016-02-0912-12/+12
| | | | | | | These were supposed to have been removed in a previous patch, but I missed them. llvm-svn: 260291
* Remove decorators related to debug info types.Zachary Turner2016-02-091-1/+1
| | | | | | All existing usages were ported over to the common decorators. llvm-svn: 260290
* Delete all the xfail / skip decorators for specific compilers.Zachary Turner2016-02-098-9/+9
| | | | | | Ported everything over to using expectedFailureAll. llvm-svn: 260289
* Remove expected failure and skip decorators for host os.Zachary Turner2016-02-096-37/+37
| | | | | | | All decorator invocations are updated to use the generic expectedFailureAll and skipIf decorators. llvm-svn: 260288
* Remove skipIfHostPlatform and skipUnlessHostPlatform decorators.Zachary Turner2016-02-092-4/+4
| | | | llvm-svn: 260177
* Remove the skipUnlessArch decorator.Zachary Turner2016-02-091-7/+7
| | | | | | Convert everything over to using skipIf. llvm-svn: 260176
* A number of improvements to decorator conditionals.Zachary Turner2016-02-082-2/+2
| | | | | | | | | | | | | | | | | | | * Change the `not_in` function to be called `no_match`. This makes it clear that keyword arguments can be more than just lists. * Change the name of `_check_list_or_lambda` to `_match_decorator_property`. Again clarifying that decorator params are not always lists. * Always use a regex match when matching strings. This allows automatic support for regex matching on all decorator properties. Also support compiled regex values. * Fix a bug in the compiler check used by _decorateTest. The two arguments were reversed, the condition was always wrong. * Change one test that uses skipUnlessArch to use skipIf, to demonstrate that skipIf can now handle more scenarios. Differential Revision: http://reviews.llvm.org/D16938 llvm-svn: 260135
* Remove expectedFailureWindows decorator.Zachary Turner2016-02-0846-78/+78
| | | | | | | | | | | | | | | expectedFailureWindows is equivalent to using the general expectedFailureAll decorator with oslist="windows". Additionally, by moving towards these common decorators we can solve the issue of having to support decorators that can be called with or without arguments. Once all decorators are always called with arguments, and this is enforced by design (because you can't specify the condition you're decorating for without passing an argument) the implementation of the decorators can become much simpler Differential Revision: http://reviews.llvm.org/D16936 llvm-svn: 260134
* Fix an issue where certain CommandObjects (or Options thereof) were being ↵Enrico Granata2016-02-061-0/+48
| | | | | | | | | | created once, bound to a specific CommandInterpreter (and hence a specific Debugger), and then cached for reuse across different Debugger instances Obviously, if the original Debugger goes away, those commands are holding on to now stale memory, which has the potential to cause crashes Fixes rdar://24460882 llvm-svn: 259964
* Move the rest of the tests over to using the new decorator module.Zachary Turner2016-02-04134-150/+301
| | | | llvm-svn: 259838
* Move some of the common decorators to decorators.py.Zachary Turner2016-02-0410-12/+20
| | | | | | | | | | | | This doesn't attempt to move every decorator. The reason for this is that it requires touching every single test file to import decorators.py. I would like to do this in a followup patch, but in the interest of keeping the patches as bite-sized as possible, I've only attempted to move the underlying common decorators first. A few tests call these directly, so those tests are updated as part of this patch. llvm-svn: 259807
* The SetStopInfo from a Mach Exception was setting the stopJim Ingham2016-02-031-1/+0
| | | | | | | | | | reason to None when we stop due to a trace, then noticed that we were on a breakpoint that was not valid for the current thread. That should actually have set it back to trace. This was pr26441 (<rdar://problem/24470203>) llvm-svn: 259684
* Move some android platform functions to lldbplatformutil.Zachary Turner2016-02-031-4/+4
| | | | | | | | | | | | | | | | | | | My eventual goal is to move all of the test decorators to their own module such as `decorators.py`. But some of the decorators use existing functions in `lldbtest.py` and conceptually the functions are probably more appropriately placed in lldbplatformutil. Moreover, lldbtest.py is a huge file with a ton of random utility functions scattered around, so this patch also workds toward the goal of reducing the footprint of this one module to a more reasonable size. So this patch moves some of them over to lldbplatformutil with the eventual goal of moving decorators over to their own module. Reviewed By: Tamas Berghammer, Pavel Labath Differential Revision: http://reviews.llvm.org/D16830 llvm-svn: 259680
* Remove skipUnlessListedRemote test decoratorPavel Labath2016-02-031-5/+0
| | | | | | | | | | | | | | This decorator was used in only one test, and it's behaviour was quite complicated. It skipped if: - test was remote - platform was *not* android I am not aware of anyone running tests with this configuration (and even then, I am not aware of a reason why the test should not pass), but if TestLoadUnload starts breaking for you after this commit, please disable the test with @expectedFailureAll(remote=True, oslist=[YOUR_PLATFORM]) llvm-svn: 259642
* Fix inverted conditional in TestInferiorAssert.pyZachary Turner2016-02-021-2/+2
| | | | llvm-svn: 259608
* Don't return a tuple from the skip test function.Zachary Turner2016-02-022-3/+3
| | | | | | | | | | | Previously we were returning a tuple of (bool, skip_reason) from the tuple function. This makes for some awkward code, especially since a value of True for the first argument implies that the second argument is None, and a value of False implies that the second argument is not None. So it was basically redundant, and with this patch we simply return the skip reason or None directly. llvm-svn: 259590
* XFAIL TestConsecutiveBreakpoints.test_single_step_thread_specific on OSXPavel Labath2016-02-021-0/+1
| | | | llvm-svn: 259527
* skip TestWatchLocation on OS XTodd Fiala2016-02-021-0/+1
| | | | | | | | Skipping this test while I investigate. It started failing with r259379. (It is generating an error due to unicode decode issues.) llvm-svn: 259526
* Remove redundant test in TestExitDuringStepPavel Labath2016-02-021-12/+4
| | | | | | | | | After recent changes, test_thread_state_is_stopped has become equivalent to test_step_in, as the function exit_during_step_base was not using the "test_thread_state" parameter. As test was XFAILed on all platforms anyway, and we have other tests for the bug which it (used to) test, I am simply removing the function. llvm-svn: 259517
* Fix single-stepping onto a breakpointPavel Labath2016-02-021-25/+67
| | | | | | | | | | | | | | | Summary: r259344 introduced a bug, where we fail to perform a single step, when the instruction we are stepping onto contains a breakpoint which is not valid for this thread. This fixes the problem and add a test case. Reviewers: tberghammer, emaste Subscribers: abhishek.aggarwal, lldb-commits, emaste Differential Revision: http://reviews.llvm.org/D16767 llvm-svn: 259488
* Set correct ThreadStopInfo in case of trace eventAbhishek Aggarwal2016-02-012-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: - The patch solves Bug 23478 and Bug 19311. Resolving Bug 23478 also resolves Bug 23039. Correct ThreadStopInfo is set for Linux and FreeBSD platforms. - Summary: When a trace event is reported, we need to check whether the trace event lands at a breakpoint site. If it lands at a breakpoint site then set the thread's StopInfo with the reason 'breakpoint'. Else, set the reason to be 'Trace'. Change-Id: I0af9765e782fd74bc0cead41548486009f8abb87 Signed-off-by: Abhishek Aggarwal <abhishek.a.aggarwal@intel.com> Reviewers: jingham, emaste, lldb-commits, clayborg, ovyalov Subscribers: emaste Differential Revision: http://reviews.llvm.org/D16720 llvm-svn: 259344
* Fix a bug where type <formatter> list would ignore the -w argumentEnrico Granata2016-01-291-0/+4
| | | | | | rdar://24379879 llvm-svn: 259135
* Fix a bug where LLDB would not print the name of the function that a ↵Enrico Granata2016-01-296-0/+92
| | | | | | | | scripted summary is bound to rdar://24380076 llvm-svn: 259131
* Fix an issue where the type <formatter> list command would not accept a ↵Enrico Granata2016-01-281-0/+26
| | | | | | | | valid argument and instead error out complaining about a malformed regex rdar://problem/24380025 llvm-svn: 259078
* Fix some python 3 incompatibilities that went in overnight.Zachary Turner2016-01-271-1/+3
| | | | | | | | * basestring is not a thing anymore. Must use `six.string_types`. * Must use from __future__ import print_function in every new test file. llvm-svn: 258967
* Refactor some of the xfail / skip decorators to share logic.Zachary Turner2016-01-273-3/+5
| | | | | | | | | | | Previously the logic of skipIf and expectedFailure were 99% the same, but they took different sets of arguments since they were maintained separately, and had slightly differences in their behavior. This makes everything consistent, there is now only one real implementation, and the previous ones are changed to use the single master implementation. llvm-svn: 258966
* Decorarte TestInferiorAssert xfails on AArch64 LinuxOmair Javaid2016-01-271-3/+3
| | | | | | This patch decorates some of TestInferiorAssert test cases with expectedFailureLinux on AArch64. llvm-svn: 258930
* [LLDB][MIPS] A small fix in GetBreakableLoadAddress() for MIPSBhushan D. Attarde2016-01-273-0/+109
| | | | | | | | | | | | | SUMMARY: Get the load address for the address given by symbol and function. Earlier, this was done for function only, this patch does it for symbol too. This patch also adds TestAvoidBreakpointInDelaySlot.py to test this change. Reviewers: clayborg Subscribers: labath, zturner, mohit.bhakkad, sagar, jaydeep, lldb-commits Differential Revision: http://reviews.llvm.org/D16049 llvm-svn: 258919
* Fix TestRerun.py on Windows.Zachary Turner2016-01-261-25/+6
| | | | | | | | This is another example of a test that was looking for the thread at index 0 instead of requesting the thread that was stopped at the created breakpoint. This assumption isn't true on Windows 10. llvm-svn: 258764
* Fix TestSyntheticCapping for Python 3.Zachary Turner2016-01-261-19/+19
| | | | | | | | | | In Python 3, whitespace inconsistences are errors. This synthetic provider had mixed tabs and spaces, as well as inconsistent indentation widths. This led to the file not being imported, and naturally the test failing. No functional change here, just whitespace. llvm-svn: 258751
* fixed TestConsecutiveBreakpoints test on OS XTodd Fiala2016-01-233-6/+6
| | | | | | Also renamed directory and class name to fix typos. llvm-svn: 258601
* More fixes related to counting threads on Windows.Zachary Turner2016-01-222-82/+31
| | | | | | | | | | | | | | | The Windows 10 loader spawns threads at startup, so tests which count threads or assume that a given user thread will be at a specific index are incorrect in this case. The fix here is to use the standard mechanisms for getting the stopped thread (which is all we are really interested in anyway) and correlating them with the breakpoints that were set, and doing checks against those things. This fixes about 6 tests on Windows 10. llvm-svn: 258586
* XFail a test from TestConditionalBreak.py on Windows.Adrian McCarthy2016-01-221-2/+3
| | | | | | Filed a bug to investigate later: llvm.org/pr26265 llvm-svn: 258578
OpenPOWER on IntegriCloud