Commit Graph

244 Commits

Author SHA1 Message Date
Enrico Granata ed4b293b68 <rdar://problem/14064994>
Fixing a test case to correctly check that the class name has changed instead of relying on GetValueDidChange()

llvm-svn: 183364
2013-06-06 00:58:37 +00:00
Sean Callanan 415422ce76 Fixes for the IR interpreter:
- Implemented the SExt instruction, and

 - eliminated redundant codepaths for constant
   handling.

Added test cases.

<rdar://problem/13244258>
<rdar://problem/13955820>

llvm-svn: 183344
2013-06-05 22:07:06 +00:00
Sean Callanan 7d01ddd6f8 Fixed value evaluation to handle null constants.
<rdar://problem/14005311>

llvm-svn: 183022
2013-05-31 17:29:03 +00:00
Ashok Thirumurthi 863bd4a534 Fixed an xpass due to r181841 on Linux with gcc. Note that the clang variant contains to xfail, and r181841 is a fix for the test.
llvm-svn: 181918
2013-05-15 20:26:30 +00:00
Daniel Malea e8bdd1f5c0 Clean up linux test decorators and add links to known bugs
- s/skipOnLinux/skipIfLinux/ to match style of every other decorator
- linkify bugizilla/PR numbers in comments

No intended change in functionality.

llvm-svn: 181913
2013-05-15 18:48:32 +00:00
Greg Clayton 609a433159 Unbreak the linux buildbot tests. This still fails for the clang that is being used on linux.
llvm-svn: 181845
2013-05-14 23:21:47 +00:00
Greg Clayton bc8d23956c Fixed the test case to pass on Darwin. This might pass on linux as well. The test case now properly validates g_points as a global for the class A version, and the static variable for the file static.
llvm-svn: 181840
2013-05-14 22:17:29 +00:00
Matt Kopec 201284a8d3 Add expression tests for a function in an anonymous namespace.
llvm-svn: 181741
2013-05-13 22:00:32 +00:00
Matt Kopec d608996610 Add temporary fix for calling c++ global/anonymous functions on Linux.
llvm-svn: 181613
2013-05-10 17:53:48 +00:00
Ashok Thirumurthi 582133e88e Skipping a test that asserts with gcc and icc to allow the test suite to run to completion on the gcc buildbot.
llvm-svn: 181512
2013-05-09 14:46:01 +00:00
Greg Clayton dbe445fdd8 Remove debug print statement.
llvm-svn: 181486
2013-05-08 23:37:59 +00:00
Jim Ingham 221d51cf84 Figure out the reply to "PlanExplainsStop" once when we stop and then use the cached
value.  This fixes problems, for instance, with the StepRange plans, where they know that
they explained the stop because they were at their "run to here" breakpoint, then deleted
that breakpoint, so when they got asked again, doh!  I had done this for a couple of plans
in an ad hoc fashion, this just formalizes it.

Also add a "ResumeRequested" in Process so that the code in the completion handlers can
tell the ShouldStop logic they want to resume rather than just directly resuming.  That allows 
us to handle resuming in a more controlled fashion.

Also, SetPublicState can take a "restarted" flag, so that it doesn't drop the run lock when
the target was immediately restarted.
--This line, and those below , will be ignored--

M    test/lang/objc/objc-dynamic-value/TestObjCDynamicValue.py
M    include/lldb/Target/ThreadList.h
M    include/lldb/Target/ThreadPlanStepOut.h
M    include/lldb/Target/Thread.h
M    include/lldb/Target/ThreadPlanBase.h
M    include/lldb/Target/ThreadPlanStepThrough.h
M    include/lldb/Target/ThreadPlanStepInstruction.h
M    include/lldb/Target/ThreadPlanStepInRange.h
M    include/lldb/Target/ThreadPlanStepOverBreakpoint.h
M    include/lldb/Target/ThreadPlanStepUntil.h
M    include/lldb/Target/StopInfo.h
M    include/lldb/Target/Process.h
M    include/lldb/Target/ThreadPlanRunToAddress.h
M    include/lldb/Target/ThreadPlan.h
M    include/lldb/Target/ThreadPlanCallFunction.h
M    include/lldb/Target/ThreadPlanStepOverRange.h
M    source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleThreadPlanStepThroughObjCTrampoline.h
M    source/Plugins/LanguageRuntime/ObjC/AppleObjCRuntime/AppleThreadPlanStepThroughObjCTrampoline.cpp
M    source/Target/StopInfo.cpp
M    source/Target/Process.cpp
M    source/Target/ThreadPlanRunToAddress.cpp
M    source/Target/ThreadPlan.cpp
M    source/Target/ThreadPlanCallFunction.cpp
M    source/Target/ThreadPlanStepOverRange.cpp
M    source/Target/ThreadList.cpp
M    source/Target/ThreadPlanStepOut.cpp
M    source/Target/Thread.cpp
M    source/Target/ThreadPlanBase.cpp
M    source/Target/ThreadPlanStepThrough.cpp
M    source/Target/ThreadPlanStepInstruction.cpp
M    source/Target/ThreadPlanStepInRange.cpp
M    source/Target/ThreadPlanStepOverBreakpoint.cpp
M    source/Target/ThreadPlanStepUntil.cpp
M    lldb.xcodeproj/xcshareddata/xcschemes/Run Testsuite.xcscheme

llvm-svn: 181381
2013-05-08 00:35:16 +00:00
Greg Clayton 5378bbaec0 Mark TestConstVariables as expected to fail due to radar 13314878 on darwin. The tests are already skipped on linux.
llvm-svn: 180965
2013-05-02 22:19:05 +00:00
Sean Callanan 99c272d3eb TestCallCPPFunction is an expected failure on
Linux; marking as such.

llvm-svn: 180832
2013-04-30 23:52:02 +00:00
Sean Callanan 8d285ada3d Added a test case verifying that simple C++
functions can be called by basename.

<rdar://problem/13709855>

llvm-svn: 180814
2013-04-30 22:05:15 +00:00
Sean Callanan a30b5b7a97 Fixed the anonymous testcase. It was testing
access to 'z' where 'z' was not in scope.

llvm-svn: 180662
2013-04-27 01:53:20 +00:00
Matt Kopec 23a03de34d Mark tests as expected fail for Linux due to not being able to call/print c++ demangled functions in the global namespace (bugzilla 15854).
llvm-svn: 180623
2013-04-26 20:04:24 +00:00
Sean Callanan 2ad6691be4 Fixed IRForTarget to handle Objective-C messages
sent to "super".

<rdar://problem/13042260>

llvm-svn: 180217
2013-04-24 21:25:20 +00:00
Sean Callanan 76ee3e7e1c Fixed expression parser handling of empty strings.
<rdar://problem/12977827>

llvm-svn: 180215
2013-04-24 19:50:12 +00:00
Sean Callanan 7f5ac65fb9 Added support for pulling Objective-C class symbols
out of the runtime.  This allows calling static methods
on classes whose symbols have been stripped out of the
binary.

<rdar://problem/12042992>

llvm-svn: 180210
2013-04-24 19:07:29 +00:00
Sean Callanan 485f732b84 Fixed a problem where the expression parser would
not find multiple functions with the same name but
different types.  Now we keep track of what types
we've already reported for a function and only elide
functions if we've already reported a conflicting
one.

Also added a test case.

<rdar://problem/11367837>

llvm-svn: 180167
2013-04-24 00:34:41 +00:00
Ashok Thirumurthi f6cd60ae68 Improved tests for nested structs when anonymous structs are involved.
- New tests can fail on OS/X and Linux, and illustrate that the compiler
used to generate the DWARF can result in lldb providing clang with an
external AST source that doesn't describe all required struct fields.

- Also includes test coverage for expressions with structs that do work on Linux- Also includes a test for dereferencing a null pointer to a struct, which works on OS/X rather than complaining, and complains on Linux with an upstream error that is really a side issue.

Thanks to Samuel, Andy and Daniel for their input.

llvm-svn: 179884
2013-04-19 20:51:34 +00:00
Ashok Thirumurthi 6ac9d13e61 Provided a variant of ReadCStringFromMemory that supports null terminators of any character width.
This prevents unbounded reads (i.e. reads of GetMaximumSizeOfStringSummary() bytes)
from causing test failures (i.e. due to ptrace EIO or EFAULT on Linux).

Note that ReadCStringFromMemory is marked as deprecated because the loop that calls
ReadMemory does not continue until the string has been completely read.
The expected behavior is to read until until max_bytes or a null terminator.

Note: As discussed on lldb-dev, further testing will be performed with ReadStringFromMemory
before further changes are made for users of ReadCStringFromMemory.

Thanks to Enrico, Matt and Andy for their review feedback.

llvm-svn: 179857
2013-04-19 15:58:38 +00:00
Enrico Granata a0f9512cb1 <rdar://problem/13558484>
This makes the dynamic values test case work for both libc++ and libstdcpp

llvm-svn: 179333
2013-04-11 22:55:45 +00:00
Enrico Granata cd58d1176f Making the buildbot happy again after changes to the default formatter for char[]
llvm-svn: 178295
2013-03-28 21:58:05 +00:00
Greg Clayton 53c5ddf0d7 Fixed incorrect python that was trying to validate that we got a valid lldb.SBThread object by checking to see if it is equal to "None".
This test is incorrect as functions that return lldb.SBThread objects never return None, they just return lldb.SBThread objects that contain invalid opaque classes. 

llvm-svn: 177416
2013-03-19 17:59:30 +00:00
Matt Kopec 0de53f062f Add icc support to the test suite
-adds icc to the lit of compilers to run the tests
-adds icc test decorators
-skip TestAnonymous.py for icc

Patch by Ashok Thirumurthi.

llvm-svn: 177174
2013-03-15 19:10:12 +00:00
Daniel Malea 10320dd06f Minor LLDB test improvements
- fix TestCPPBool (was failing with some versions of GCC due to num_breakpoint_locations)
- speed up tests by skipping git/svn revision parsing by the test harness when running in lit-compatible (parsable) mode

This should resolve the failures reported by http://lab.llvm.org:8011/builders/lldb-x86_64-linux

llvm-svn: 176972
2013-03-13 20:50:05 +00:00
Daniel Malea 7f454e0aed Fix enum_types test on Linux
- Required flag "-std=c++11" needs to be set before including Makefile.rules

llvm-svn: 176644
2013-03-07 20:13:11 +00:00
Andrew Kaylor 7bdeab592d Skipping TestConstVariables on Linux.
The test was marked as expectedFailureLinux, but now it passes with gcc and some versions of clang.  Newer versions of clang introduce a failure due to bad DWARF information.

llvm-svn: 176581
2013-03-06 21:37:41 +00:00
Greg Clayton 5d14fc061f Fixed enum printing for negative enums. There previously was no testing to validate that enum values were being displayed correctly.
Also added C++11 enum test cases to cover enums as int8_t, int16_t int32_t, int64_t, uint8_t, uint16_t, uint32_t, and uint64_t both for DWARF and dSYM cases. The DWARF being emitted by clang is missing the enum integer type, but the code is now ready to accept and deal with the integral type if it is supplied.

llvm-svn: 176548
2013-03-06 06:23:54 +00:00
Greg Clayton 2a844b7ff8 Fixed test suite errors due to new clang -v output.
llvm-svn: 176546
2013-03-06 02:34:51 +00:00
Daniel Malea 658fd5798b Un-skipping tests affected by llvm.org/pr15256
patch by Ashok Thirumurthi!

llvm-svn: 176462
2013-03-04 23:15:08 +00:00
Daniel Malea 9e84eb41f6 Add a test case for static member variables
- expected to fail across the board due to llvm.org/pr15401

Patch by Ashok Thirumurthi!

llvm-svn: 176362
2013-03-01 18:25:42 +00:00
Greg Clayton e595c6bf3c Replace all "-gdwarf-2" with "-g" to use the compiler defaults.
llvm-svn: 176283
2013-02-28 18:47:39 +00:00
Greg Clayton 0d5911cbe9 Fixed an issue where the LDFLAGS were not correctly gettting modified to be additive.
llvm-svn: 176281
2013-02-28 18:45:39 +00:00
Matt Kopec 00049b8b96 Add GNU indirect function support in expressions for Linux.
llvm-svn: 176206
2013-02-27 20:13:38 +00:00
Daniel Malea 0aea016b06 Cleanup TestUniqueTypes.py and add getCompilerVersion() to test harness
- pull up logic to get compiler version from TestUniqueTypes.py into lldbtest.py
- work around an GCC 4.6.3 issue

llvm-svn: 176190
2013-02-27 17:29:46 +00:00
Jim Ingham 344d36aa9f Mark a few more tests as "basic_process".
llvm-svn: 176132
2013-02-26 22:51:48 +00:00
Jim Ingham d882998eff Fix the .categories, it had "dataformatter" not "dataformatters".
Remove the getCategory from TestDataFormatterObjC.py, since it was superceded by the .categories file, 
and didn't work anyway (getCategories currently has to be a method on the test class, not on the test.)
Add a "basic_process" category, and start to find some tests for simple process running sniff tests.

llvm-svn: 176061
2013-02-25 23:51:06 +00:00
Enrico Granata 43f6213352 Fixing issues in previous checkin - still figuring out how to make expectedFailureClang take the bugnumber
llvm-svn: 175945
2013-02-23 01:28:30 +00:00
Enrico Granata e6cedc1296 <rdar://problem/12362092>
The decorators @expectedFailure (plain and special-case like i386, clang, ...) are modified to optionally take a bugnumber argument
If such an argument is specified, the failure report (or unexpected success report) will include the information passed in as part of the message
This is mostly useful for associating failures to issue IDs in issue management systems (e.g. the LLVM bugzilla)

llvm-svn: 175942
2013-02-23 01:05:23 +00:00
Daniel Malea da6921eb55 Mark last known Linux failure as XFAIL to see if there's any other problems with buildbots.
llvm-svn: 175917
2013-02-22 20:23:34 +00:00
Daniel Malea c6a70063cb Fix invalid TestBitfields case (thanks Filipe!), and xfail one case due to GCC compiler bug.
Turns out unnamed bit fields should not be accessed ever in C (C99 section 4.7.8) or C++
(C++11 section 9.6). 

Unrelated to the above, this commit marks TestBitfields as expected-to-fail with GCC as 4.7
has problems with padding... the size of the struct with a uint32_t member is reported as 12
when GCC is used. Clang emits correct code.

Parts of this patch prepared by Filipe Cabecinhas!

llvm-svn: 175666
2013-02-20 21:11:20 +00:00
Daniel Malea 294c5e1cc3 Fix a problem with the const_variables test case (another lldb bug remains)
- make the test case step past the location where 'index' is initialized, otherwise its value cannot be printed (verified gcc 4.6/4.7 and recent clang)
- "Couldn't materialize struct" error from LLDB still prevents this test case from passing

llvm-svn: 175653
2013-02-20 19:41:49 +00:00
Daniel Malea 5b7c14b3c8 A few more GCC specific test fixes as per logged PRs:
- TestNamespace expected to fail due to PR-15302
- TestCPPBool and TestUnsignedTypes updated to handle GCC style debug information
- TestRvalueReferences expected fail due to GCC (4.7) not outputting rvalue-reference debug information
- TestDataFormatterStdVBool expected to fail due to PR-15301

llvm-svn: 175551
2013-02-19 19:54:16 +00:00
Enrico Granata a5da2adc77 NSWindows should only be created after you have an NSApplication
llvm-svn: 175475
2013-02-19 00:39:59 +00:00
Daniel Malea e78ecc2cc7 More test case cleanup (Linux and Mac):
- remove expectedFailure decorator from resolved rdar 12566646 and 10887661
- remove expectedFailure from TestBitfields testcase not actually affected by bug
- skip the (non-deterministic) TestStopHookMechanism.py to avoid a noisy suite on Linux

llvm-svn: 175307
2013-02-15 21:27:14 +00:00
Daniel Malea 90e9fd9cbb Fix broken testcase: ignore LLDB output that warns about more elements than can be displayed.
- test could be re-written at some point, but right now just trying to clean up known failures for the linux buildbot.

llvm-svn: 175114
2013-02-14 00:30:40 +00:00
Daniel Malea e651aee927 Marking two tests expected-to-fail on Linux
- PR-15260: lldb does not display correct value of 1-bit field
- PR-16261: lldb does not display size of (file/class) static array

llvm-svn: 175111
2013-02-14 00:20:44 +00:00