summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/functionalities
Commit message (Collapse)AuthorAgeFilesLines
* Attempt to fix TestCPPBreakpointLocations on Linux/Android.Oleksiy Vyalov2016-04-131-1/+1
| | | | llvm-svn: 266164
* Fix breakpoint_set_restart test for WindowsAdrian McCarthy2016-04-121-2/+8
| | | | | | | | When run with the multiprocess test runner, the getchar() trick doesn't work, so ninja check-lldb would fail on this test, but running the test directly worked fine. Differential Revision: http://reviews.llvm.org/D19035 llvm-svn: 266145
* Fixed being able to set breakpoints on destructors when we don't fully ↵Greg Clayton2016-04-121-0/+3
| | | | | | | | | | | | | | specify the demangled name. So all of the following now work: (lldb) b ~Foo (lldb) b Foo::~Foo (lldb) b Bar::Foo::~Foo Improved out C++ breakpoint locations tests as well to cover this issue. <rdar://problem/25577252> llvm-svn: 266139
* Breakpoint conditions were making result variables, which they should not do. Jim Ingham2016-04-121-0/+4
| | | | | | | | | | | | | | The result variables aren't useful, and if you have a breakpoint on a common function you can generate a lot of these. So I changed the code that checks the condition to set ResultVariableIsInternal in the EvaluateExpressionOptions that we pass to the execution. Unfortunately, the check for this variable was done in the wrong place (the static UserExpression::Evaluate) which is not how breakpoint conditions execute expressions (UserExpression::Execute). So I moved the check to UserExpression::Execute (which Evaluate also calls) and made the overridden method DoExecute. llvm-svn: 266093
* 'int' is reported as an exception on OS X not as a signal. I don't thinkJim Ingham2016-04-121-1/+1
| | | | | | this test ever succeeded on OS X. llvm-svn: 266092
* Fixup TestFdLeakPavel Labath2016-04-121-3/+5
| | | | | | | this test was unintentionally XFAILed due to a change in the behavior of the expectedFailure decorator. Fix that. Also, mark the test as debug-info independent while I'm in there. llvm-svn: 266072
* Add a ThreadSanitizer testcase that tests multiple reported issues.Kuba Brecka2016-04-103-0/+212
| | | | llvm-svn: 265906
* Provide more information in ThreadSanitizer's JSON data. Move remaining ↵Kuba Brecka2016-04-101-2/+2
| | | | | | TSan logic from SBThread to InstrumentationRuntime plugin. llvm-svn: 265905
* Fix TestBreakpointSetRestart failure on Android.Oleksiy Vyalov2016-04-091-6/+12
| | | | llvm-svn: 265869
* Remove what I believe are the last known instances of formatters that run codeEnrico Granata2016-04-084-48/+11
| | | | llvm-svn: 265865
* Remove even more of the data formatters that silently run codeEnrico Granata2016-04-082-31/+1
| | | | | | Fixes <rdar://problem/25629755> llvm-svn: 265849
* Reset continue_after_async only if neither SIGINIT nor SIGSTOP received.Oleksiy Vyalov2016-04-083-0/+61
| | | | | | http://reviews.llvm.org/D18886 llvm-svn: 265843
* Enabling AddressSanitizer tests, they should pass now (and this time I mean it).Kuba Brecka2016-04-072-2/+0
| | | | llvm-svn: 265656
* Enable TestDebugBreak on x86_64 as wellPavel Labath2016-04-071-1/+1
| | | | | | Test passes there, and this would have helped me catch the snafu in the previous commit. llvm-svn: 265650
* Fixup TestLinuxCore on windowsPavel Labath2016-04-061-0/+2
| | | | | | | test_same_pid_running couldn't delete the temporary files, while we had them open. Deleting the target should make things work. llvm-svn: 265529
* Revert "XFail TestImport.py on Windows because Python 3 import rules don't ↵Adrian McCarthy2016-04-051-1/+0
| | | | | | | | work that way." This reverts commit e5f0ba4fcf977ad6baaaca700d3646675cdac19b. llvm-svn: 265476
* XFail TestImport.py on Windows because Python 3 import rules don't work that ↵Adrian McCarthy2016-04-051-0/+1
| | | | | | way. llvm-svn: 265461
* Reverting r265401 ("Enabling AddressSanitizer tests, they should work now.")Kuba Brecka2016-04-052-0/+2
| | | | llvm-svn: 265406
* Enabling AddressSanitizer tests, they should work now.Kuba Brecka2016-04-052-2/+0
| | | | llvm-svn: 265401
* Fixing AddressSanitizer tests (update expectations for current ASan, make it ↵Kuba Brecka2016-04-052-23/+13
| | | | | | work on OS X 10.10 and older). llvm-svn: 265400
* [NFC] Cleanup the code used to run shell commands from testsTamas Berghammer2016-04-052-44/+2
| | | | | | | | | | | | Previously we had 3 different method to run shell commands on the target and 4 copy of code waiting until a given file appears on the target device (used for syncronization). This CL merges these methods to 1 run_platform_command and 1 wait_for_file_on_target functions located in some utility classes. Differential revision: http://reviews.llvm.org/D18789 llvm-svn: 265398
* Enabling TSan tests, they should work now.Kuba Brecka2016-04-052-2/+0
| | | | llvm-svn: 265396
* Fix ThreadSanitizer test cases to work on OS X 10.10 and older.Kuba Brecka2016-04-052-0/+10
| | | | llvm-svn: 265395
* Fix a bug in linux core file handlingPavel Labath2016-04-055-8/+71
| | | | | | | | | | | | | | | | | | | Summary: There was a bug in linux core file handling, where if there was a running process with the same process id as the id in the core file, the core file debugging would fail, as we would pull some pieces of information (ProcessInfo structure) from the running process instead of the core file. I fix this by routing the ProcessInfo requests through the Process class and overriding it in ProcessElfCore to return correct data. A (slightly convoluted) test is included. Reviewers: clayborg, zturner Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D18697 llvm-svn: 265391
* Improve the way LLDB escapes arguments before passing them to the shellEnrico Granata2016-04-041-1/+5
| | | | | | | | | | | | | Teach LLDB that different shells have different characters they are sensitive to, and use that knowledge to do shell-aware escaping This helps solve a class of problems on OS X where LLDB would try to launch via sh, and run into problems if the command line being passed to the inferior contained such special markers (hint: the shell would error out and we'd fail to launch) This makes those launch scenarios work transparently via shell expansion Slightly improve the error message when this kind of failure occurs to at least suggest that the user try going through 'process launch' directly Fixes rdar://problem/22749408 llvm-svn: 265357
* disabled TSAN tests until the author can help track down CI failuresTodd Fiala2016-04-042-0/+2
| | | | | | | These tests run fine locally for me but are failing on the Green Dragon OS X CI. llvm-svn: 265342
* Fix flakyness in TestWatchpointMultipleThreadsPavel Labath2016-04-042-7/+2
| | | | | | | This addresses the same problem as r264846 (the test not expecting the situation when two thread hit the watchpoint simultaneously), but for a different test. llvm-svn: 265294
* skip and xfail two std::list-related libcxx tests that fail on OS X with TOT ↵Todd Fiala2016-04-012-0/+2
| | | | | | | | | | | | | libcxx Enrico has a bug on him to make this work across older libcxx list and newer libcxx list simultaneously. Needed in preparation of getting the OS X public CI to run the TSAN tests. tracked by: rdar://25499635 llvm-svn: 265188
* Remove more of the code-running ObjC data formatter supportEnrico Granata2016-04-011-6/+1
| | | | llvm-svn: 265181
* Enhance the 'type X list' commands such that they actually alert the user if ↵Enrico Granata2016-03-302-1/+4
| | | | | | no formatters matching the constraints could be found llvm-svn: 264957
* Fix flakyness in TestWatchpointMultipleThreadsPavel Labath2016-03-302-13/+3
| | | | | | | | | | | | | | | | | | | | | | Summary: the inferior in the test deliberately does not lock a mutex when accessing the watched variable. The reason for that is unclear as, based on the logs, the original intention of the test was to check whether watchpoints get propagated to newly created threads, which should work fine even with a mutex. Furthermore, in the unlikely event (which I have still observed happening from time to time) that two threads do manage the execute the "critical section" simultaneously, the test will fail, as it is expecting the watchpoint "hit count" to be 1, but in this case it will be 2. Given this, I have simply chose to lock the mutex always, so that we have more predictible behavior. Watchpoints being hit simultaneously is still (and correctly!) tested by TestConcurrentEvents. Reviewers: clayborg, jingham Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D18558 llvm-svn: 264846
* Fixed the failing test TestCommandScriptImmediateOutput on MacOSX. Turns out ↵Greg Clayton2016-03-302-5/+5
| | | | | | | | | | | | | | | | | | | | | that there are few things to watch out for when writing pexpect tests: 1 - If you plan on looking for the "(lldb) " prompt as a regular expression, look for "\(lldb\) " so you don't just find "lldb". 2 - Make sure to not use colors (specify --no-use-colors as an option to lldb when launching it) as our editline will print: "(lldb) <color junk>(lldb) " where "<color junk>" is a work around that is used to allow us to colorize our prompts. The bad thing is this will make pexepct code like this not execute as you would expect: prompt = "\(lldb\) " self.child.sendline("breakpoint set ...", prompt) self.child.sendline("breakpoint clear ...", prompt) The problem is the first "sendline" will create two lldb prompts and will match both the first and second prompts and you output will get off. So be sure to disable colors if you need to. Fixed a case where "TestCommandScriptImmediateOutput.py" would fail if you have spaces in your directory names. I modified custom_command.py to use shlex to parse arguments and I quoted the file path we sent down to the custom_command.write_file function. llvm-svn: 264810
* Fix an issue with nested aliases where the help system wouldn't correctly ↵Enrico Granata2016-03-251-0/+8
| | | | | | | | track the fact that an alias is an alias to a dash-dash alias (and I hope I typed the word 'alias' enough times in this commit message :-) llvm-svn: 264468
* Make File option flags consistent for Python APIStephane Sezer2016-03-242-1/+44
| | | | | | | | | | | | | | | | | | Summary: Fixes SBCommandReturnObject::SetImmediateOutputFile() and SBCommandReturnObject::SetImmediateOutputFile() for files opened with "a" or "a+" by resolving inconsistencies between File and our Python parsing of file objects. Reviewers: granata.enrico, Eugene.Zelenko, jingham, clayborg Subscribers: lldb-commits, sas Differential Revision: http://reviews.llvm.org/D18228 Change by Francis Ricci <fjricci@fb.com> llvm-svn: 264351
* Make 'type lookup' print an error message instead of complete radio silence ↵Enrico Granata2016-03-241-0/+1
| | | | | | | | when it can't find a type matching user input It would be fun to make it provide suggestions (e.g. 'can't find NString, did you mean NSString instead?'), but this worries me a little bit on the account of just how thorough of a type system scan it would have to do llvm-svn: 264343
* Add ThreadSanitizer debugging support.Kuba Brecka2016-03-236-0/+219
| | | | | | | | | | | | This patch adds ThreadSanitizer support into LLDB: - Adding a new InstrumentationRuntime plugin, ThreadSanitizerRuntime, in the same way ASan is implemented. - A breakpoint stops in `__tsan_on_report`, then we extract all sorts of information by evaluating an expression. We then populate this into StopReasonExtendedInfo. - SBThread gets a new API, SBThread::GetStopReasonExtendedBacktraces(), which returns TSan’s backtraces in the form of regular SBThreads. Non-TSan stop reasons return an empty collection. - Added some test cases. Reviewed by Greg Clayton. llvm-svn: 264162
* Change 'apropos' such that it doesn't look into the "long help/syntax" ↵Enrico Granata2016-03-231-1/+1
| | | | | | | | | | strings for commands This solves issues such as 'apropos foo' returning valid matches just because syntax examples happen to use 'foo' as a placeholder token Fixes rdar://9043025 llvm-svn: 264123
* Fix a bug caused by my alias refactoring where, if an alias was defined in ↵Enrico Granata2016-03-223-0/+87
| | | | | | terms of another alias, trying to run the nested command would actually cause a crash in the command interpreter llvm-svn: 264096
* Add a DiagnosticManager replace error streams in the expression parser.Sean Callanan2016-03-191-42/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | We want to do a better job presenting errors that occur when evaluating expressions. Key to this effort is getting away from a model where all errors are spat out onto a stream where the client has to take or leave all of them. To this end, this patch adds a new class, DiagnosticManager, which contains errors produced by the compiler or by LLDB as an expression is created. The DiagnosticManager can dump itself to a log as well as to a string. Clients will (in the future) be able to filter out the errors they're interested in by ID or present subsets of these errors to the user. This patch is not intended to change the *users* of errors - only to thread DiagnosticManagers to all the places where streams are used. I also attempt to standardize our use of errors a bit, removing trailing newlines and making clients omit 'error:', 'warning:' etc. and instead pass the Severity flag. The patch is testsuite-neutral, with modifications to one part of the MI tests because it relied on "error: error:" being erroneously printed. This patch fixes the MI variable handling and the testcase. <rdar://problem/22864976> llvm-svn: 263859
* Fix thread/process ID reading from linux core filesPavel Labath2016-03-167-0/+94
| | | | | | | | | | | | | | | | | Summary: This also adds a basic smoke test for linux core file reading. I'm checking in the core files as well, so that the tests can run on all platforms. With some tricks I was able to produce reasonably-sized core files (~40K). This fixes the first part of pr26322. Reviewers: zturner Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D18176 llvm-svn: 263628
* On some platforms, the compiler is allowed to assume that BOOL == bool. On ↵Enrico Granata2016-03-152-1/+9
| | | | | | | | | | | | others, BOOL == signed char. This can cause differences in which bit patterns end up meaning YES or NO. In general, however, 0 == NO and 1 == YES. To keep it simple, LLDB will now show "YES" and "NO" only for 1 and 0 respectively, and format other values as the plain numeric value instead. Fixes rdar://24809994 llvm-svn: 263604
* Make it so that the data formatter for NSError can see through a variable of ↵Enrico Granata2016-03-152-5/+8
| | | | | | type NSError**. Fixes rdar://25060684 llvm-svn: 263603
* Fixed MemoryCache L1 cache flushMarianne Mailhot-Sarrasin2016-03-113-0/+81
| | | | | | | | Use the same method to find the cache line as in Read(). Differential Revision: http://reviews.llvm.org/D18050 llvm-svn: 263233
* [LLDB][MIPS] Fix TestDisassembleBreakpointMohit K. Bhakkad2016-03-071-1/+1
| | | | | | | | | | Patch by Nitesh Jain Reviewers: clayborg, jaydeep. Subscribers: bhushan, mohit.bhakkad, sagar, lldb-commits. Differential Revision: http://reviews.llvm.org/D17597 llvm-svn: 262819
* Revert a part of "Add/Improve complex, vector, aggregate types handling for ↵Pavel Labath2016-02-291-3/+3
| | | | | | | | | | | | SysV ARM (hard/soft) ABI." This partially reverts commit r262218. The commit added additional checks to a test case. The test case is too big so it's not feasible to XFAIL it completely. Suggest to implement the checks as a separate test case, which can then be XFAILed more surgically. llvm-svn: 262223
* Add/Improve complex, vector, aggregate types handling for SysV ARM ↵Omair Javaid2016-02-291-3/+3
| | | | | | | | | | (hard/soft) ABI. For details see: Differential revision: http://reviews.llvm.org/D17708 llvm-svn: 262218
* [LLDB][MIPS] Fix TestInferiorAssert.py for MIPSSagar Thakur2016-02-261-0/+4
| | | | | | | | | | | Patch by Nitesh Jain. Summary: The debug version of libc.so is require for backtracing which may not be available on all platforms. Reviewers: ovyalov, clayborg Subscribers: zturner, lldb-commits, mohit.bhakkad, sagar, bhushan, jaydeep Differential: http://reviews.llvm.org/D17131 llvm-svn: 262011
* 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
OpenPOWER on IntegriCloud