summaryrefslogtreecommitdiffstats
path: root/lldb/test/functionalities/data-formatter
Commit message (Collapse)AuthorAgeFilesLines
...
* <rdar://problem/12426557> Fixing the NSIndexSet data formatterEnrico Granata2012-10-051-1/+1
| | | | llvm-svn: 165341
* <rdar://problem/12099592> Adding back a bunch of code-running summariesEnrico Granata2012-10-032-0/+21
| | | | llvm-svn: 165186
* Missed a few places where I didn't delete the obsolete (commented out) ↵Jim Ingham2012-09-221-4/+0
| | | | | | version of the breakpoint creation. llvm-svn: 164436
* Fix all the test case breakages caused by folks writing tests all over the ↵Jim Ingham2012-09-2231-160/+80
| | | | | | | | place that depended explicitly on the output of "break set". Please don't do this sort of thing!!!!! llvm-svn: 164433
* Initial commit of a new testsuite feature: test categories.Enrico Granata2012-09-213-0/+6
| | | | | | | | | | | | | | | | | | | | | | | This feature allows us to group test cases into logical groups (categories), and to only run a subset of test cases based on these categories. Each test-case can have a new method getCategories(self): which returns a list of strings that are the categories to which the test case belongs. If a test-case does not provide its own categories, we will look for categories in the class that contains the test case. If that fails too, the default implementation looks for a .category file, which contains a comma separated list of strings. The test suite will recurse look for .categories up until the top level directory (which we guarantee will have an empty .category file). The driver dotest.py has a new --category <foo> option, which can be repeated, and specifies which categories of tests you want to run. (example: ./dotest.py --category objc --category expression) All tests that do not belong to any specified category will be skipped. Other filtering options still exist and should not interfere with category filtering. A few tests have been categorized. Feel free to categorize others, and to suggest new categories that we could want to use. All categories need to be validly defined in dotest.py, or the test suite will refuse to run when you use them as arguments to --category. In the end, failures will be reported on a per-category basis, as well as in the usual format. This is the very first stage of this feature. Feel free to chime in with ideas for improvements! llvm-svn: 164403
* <rdar://problem/12161825> Rephrase formatter for NSIndexSet in terms of ↵Enrico Granata2012-09-182-3/+3
| | | | | | indexes instead of objects llvm-svn: 164149
* <rdar://problem/11988289> Making C++ synthetic children provider for ↵Enrico Granata2012-09-183-0/+123
| | | | | | NSDictionary and related classes llvm-svn: 164144
* <rdar://problem/11086338> Implementing support for synthetic children ↵Enrico Granata2012-09-133-0/+126
| | | | | | generated by running C++ code instead of Python scripts ; Adding a bunch of value-generating APIs to our private code layer ; Providing synthetic children for NSArray llvm-svn: 163818
* <rdar://problem/11485744> Implement important data formatters in C++. Have ↵Enrico Granata2012-09-041-2/+0
| | | | | | the Objective-C language runtime plugin expose class descriptors objects akin to the objc_runtime.py Pythonic implementation. Rewrite the data formatters for some core Cocoa classes in C++ instead of Python. llvm-svn: 163155
* <rdar://problem/11589605> Making a Enrico Granata2012-08-141-1/+1
| | | | | | | 'type category enable *' command to match 'type category disable *' llvm-svn: 161882
* <rdar://problem/11578397> Adding a new --summary-string option for the frame ↵Enrico Granata2012-08-091-8/+10
| | | | | | variable command which allows the user to provide a summary string with which he wants to display the variables without having to make a named summary first llvm-svn: 161623
* <rdar://problem/10449092> Adding a new uppercase hex format specifier. This ↵Enrico Granata2012-08-093-0/+129
| | | | | | commit also changes the short names for formats so that uppercase hex can be 'X', which was previously assigned to hex float. hex float now has no short name. llvm-svn: 161606
* Now that the testcase is fixed, it is no longerSean Callanan2012-08-091-2/+0
| | | | | | an expected failure. llvm-svn: 161556
* <rdar://problem/12061386> Fixing data-formatter-cpp test case - previous ↵Enrico Granata2012-08-091-1/+4
| | | | | | version had an unfortunate dependency on the value of uninitialized memory llvm-svn: 161555
* The C++ data formatter tests are flaky. MarkingSean Callanan2012-08-091-0/+2
| | | | | | them as expected failures until they are fixed. llvm-svn: 161547
* <rdar://problem/11773899> Formatters for BOOL* and BOOL&Enrico Granata2012-07-133-0/+124
| | | | llvm-svn: 160181
* <rdar://problem/11628688> Making sure to use the ostype format for OSType valuesEnrico Granata2012-07-133-0/+102
| | | | llvm-svn: 160180
* <rdar://problem/11753405> Making sure we deal correctly with signed NSNumber ↵Enrico Granata2012-07-132-2/+13
| | | | | | values llvm-svn: 160179
* <rdar://problem/11755446> Making sure to provide summaries for one more ↵Enrico Granata2012-06-282-0/+6
| | | | | | NSString subclass llvm-svn: 159389
* Fixing a bug where the summary for certain NSStrings was being returned as ↵Enrico Granata2012-05-152-0/+4
| | | | | | empty in spite of the string actually having a content llvm-svn: 156793
* <rdar://problem/11338654> Fixing a bug where having a summary for a bitfield ↵Enrico Granata2012-05-082-1/+6
| | | | | | without a format specified would in certain cases crash LLDB - This has also led to refactoring the by-type accessors for the data formatter subsystem. These now belong in our internal layer, and are just invoked by the public API stratum llvm-svn: 156429
* Adding a new 'type category disable *' feature that disables all categories ↵Enrico Granata2012-05-033-0/+129
| | | | | | - This is intended as a quick kill switch for data formatters for cases where the user wants as little extra processing as possible to be done on their target, or to override major data formatters bug, should they occur llvm-svn: 156044
* Automatically enabling the Cocoa formatter categories for command-line LLDB. ↵Enrico Granata2012-04-263-50/+1
| | | | | | Previously, the categories were filled in but disabled by default. Tweaking test cases appropriately to keep working and do the right thing llvm-svn: 155605
* Removing the @expectedFailurei386 decorator from test cases that now work as ↵Enrico Granata2012-04-246-12/+0
| | | | | | a result of the latest changes to Value.cpp llvm-svn: 155419
* Add expected failure decorators for test cases which are failing for i386 ↵Johnny Chen2012-04-196-0/+12
| | | | | | | | architecture. Plus fix some test cases to skip/succeed for i386. llvm-svn: 155087
* Add a new option to the test driver, -N dsym or -N dwarf, in order to ↵Johnny Chen2012-04-0623-0/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | exclude tests decorated with either @dsym_test or @dwarf_test to be executed during the testsuite run. There are still lots of Test*.py files which have not been decorated with the new decorator. An example: # From TestMyFirstWatchpoint.py -> class HelloWatchpointTestCase(TestBase): mydir = os.path.join("functionalities", "watchpoint", "hello_watchpoint") @dsym_test def test_hello_watchpoint_with_dsym_using_watchpoint_set(self): """Test a simple sequence of watchpoint creation and watchpoint hit.""" self.buildDsym(dictionary=self.d) self.setTearDownCleanup(dictionary=self.d) self.hello_watchpoint() @dwarf_test def test_hello_watchpoint_with_dwarf_using_watchpoint_set(self): """Test a simple sequence of watchpoint creation and watchpoint hit.""" self.buildDwarf(dictionary=self.d) self.setTearDownCleanup(dictionary=self.d) self.hello_watchpoint() # Invocation -> [17:50:14] johnny:/Volumes/data/lldb/svn/ToT/test $ ./dotest.py -N dsym -v -p TestMyFirstWatchpoint.py LLDB build dir: /Volumes/data/lldb/svn/ToT/build/Debug LLDB-137 Path: /Volumes/data/lldb/svn/ToT URL: https://johnny@llvm.org/svn/llvm-project/lldb/trunk Repository Root: https://johnny@llvm.org/svn/llvm-project Repository UUID: 91177308-0d34-0410-b5e6-96231b3b80d8 Revision: 154133 Node Kind: directory Schedule: normal Last Changed Author: gclayton Last Changed Rev: 154109 Last Changed Date: 2012-04-05 10:43:02 -0700 (Thu, 05 Apr 2012) Session logs for test failures/errors/unexpected successes will go into directory '2012-04-05-17_50_49' Command invoked: python ./dotest.py -N dsym -v -p TestMyFirstWatchpoint.py compilers=['clang'] Configuration: arch=x86_64 compiler=clang ---------------------------------------------------------------------- Collected 2 tests 1: test_hello_watchpoint_with_dsym_using_watchpoint_set (TestMyFirstWatchpoint.HelloWatchpointTestCase) Test a simple sequence of watchpoint creation and watchpoint hit. ... skipped 'dsym tests' 2: test_hello_watchpoint_with_dwarf_using_watchpoint_set (TestMyFirstWatchpoint.HelloWatchpointTestCase) Test a simple sequence of watchpoint creation and watchpoint hit. ... ok ---------------------------------------------------------------------- Ran 2 tests in 1.138s OK (skipped=1) Session logs for test failures/errors/unexpected successes can be found in directory '2012-04-05-17_50_49' [17:50:50] johnny:/Volumes/data/lldb/svn/ToT/test $ llvm-svn: 154154
* Fixing an issue where Unicode characters in an NSString were printed as ↵Enrico Granata2012-03-292-1/+59
| | | | | | escape sequences by the summary provider shipping with LLDB - Added relevant test case code. Bonus points for identifying the source of the quotes :-) llvm-svn: 153624
* Fixing an issue where saying 'po foo' made both the summary and the ↵Enrico Granata2012-03-281-0/+6
| | | | | | description for foo come out. If one is po'ing something they most probably only care about the description - We will not omit the summary llvm-svn: 153608
* adding a summary for Objective-C type 'Class'Enrico Granata2012-03-272-0/+20
| | | | llvm-svn: 153541
* Synthetic values are now automatically enabled and active by default. ↵Enrico Granata2012-03-274-45/+42
| | | | | | | | | | | | SBValue is set up to always wrap a synthetic value when one is available. A new setting enable-synthetic-value is provided on the target to disable this behavior. There also is a new GetNonSyntheticValue() API call on SBValue to go back from synthetic to non-synthetic. There is no call to go from non-synthetic to synthetic. The test suite has been changed accordingly. Fallout from changes to type searching: an hack has to be played to make it possible to use maps that contain std::string due to the special name replacement operated by clang Fixing a test case that was using libstdcpp instead of libc++ - caught as a consequence of said changes to type searching llvm-svn: 153495
* <rdar://problem/11113279>Greg Clayton2012-03-262-13/+1
| | | | | | | | | | Fixed type lookups to "do the right thing". Prior to this fix, looking up a type using "foo::bar" would result in a type list that contains all types that had "bar" as a basename unless the symbol file was able to match fully qualified names (which our DWARF parser does not). This fix will allow type matches to be made based on the basename and then have the types that don't match filtered out. Types by name can be fully qualified, or partially qualified with the new "bool exact_match" parameter to the Module::FindTypes() method. This fixes some issue that we discovered with dynamic type resolution as well as improves the overall type lookups in LLDB. llvm-svn: 153482
* Removing cascading through inheritance chains for data formattersEnrico Granata2012-03-223-37/+21
| | | | | | | | | | | | | | | This is the feature that allowed the user to have things like: class Base { ... }; class Derived : public Base { ... }; and have formatters defined for Base work automatically for Derived. This feature turned out to be too expensive since it requires completing types. This patch takes care of removing cascading (other than typedefs chain cascading), updating the test suite accordingly, and adding required Cocoa class names to keep the AppKit formatters working llvm-svn: 153272
* Massive enumeration name changes: a number of enums in ValueObject were not ↵Enrico Granata2012-03-198-37/+133
| | | | | | | | | | | | | | | | | | following the naming pattern Changes to synthetic children: - the update(self): function can now (optionally) return a value - if it returns boolean value True, ValueObjectSyntheticFilter will not clear its caches across stop-points this should allow better performance for Python-based synthetic children when one can be sure that the child ValueObjects have not changed - making a difference between a synthetic VO and a VO with a synthetic value: now a ValueObjectSyntheticFilter will not return itself as its own synthetic value, but will (correctly) claim to itself be synthetic - cleared up the internal synthetic children architecture to make a more consistent use of pointers and references instead of shared pointers when possible - major cleanup of unnecessary #include, data and functions in ValueObjectSyntheticFilter itself - removed the SyntheticValueType enum and replaced it with a plain boolean (to which it was equivalent in the first place) Some clean ups to the summary generation code Centralized the code that clears out user-visible strings and data in ValueObject More efficient summaries for libc++ containers llvm-svn: 153061
* Changed several of the Cocoa formatters to match the output style that Xcode ↵Enrico Granata2012-03-132-28/+28
| | | | | | | | | | | uses internally to provide summaries This has been done for those summaries where the difference is only cosmetic (e.g. naming things as items instead of values, ...) The LLDB output style has been preserved when it provides more information (e.g. telling the type as well as the value of an NSNumber) Test cases have been updated to reflect the updated output style where necessary llvm-svn: 152592
* Added formatters for libc++ (http://libcxx.llvm.org):Enrico Granata2012-03-1218-6/+863
| | | | | | | | | | | | | std::string has a summary provider std::vector std::list and std::map have both a summary and a synthetic children provider Given the usage of a custom namespace (std::__1::classname) for the implementation of libc++, we keep both libstdcpp and libc++ formatters enabled at the same time since that raises no conflicts and enabled for seamless transition between the two The formatters for libc++ reside in a libcxx category, and are loaded from libcxx.py (to be found in examples/synthetic) The formatters-stl test cases have been divided to be separate for libcxx and libstdcpp. This separation is necessary because (a) we need different compiler flags for libc++ than for libstdcpp (b) libc++ inlines a lot more than libstdcpp and some code changes were required to accommodate this difference llvm-svn: 152570
* Fixing some of the new Python formatters to report '1 object' instead of '1 ↵Enrico Granata2012-03-073-0/+158
| | | | | | objects' llvm-svn: 152186
* Correct wrong values in the test caseEnrico Granata2012-03-031-2/+2
| | | | llvm-svn: 151982
* Currently TestDataFormatterPythonSynth is failing because of an issue with ↵Enrico Granata2012-03-035-25/+182
| | | | | | children capping. Splitting the test case in two so we better isolate the issue and also for better logical separation llvm-svn: 151966
* added a new formatter for CF(Mutable)BitVectorEnrico Granata2012-03-032-0/+32
| | | | | | | | fixed a few potential NULL-pointer derefs in ValueObject we have a way to provide docstrings for properties we add to the SWIG layer - a few of these properties have a docstring already, more will come in future commits added a new bunch of properties to SBData to make it more natural and Python-like to access the data they contain llvm-svn: 151962
* having std::vector still show children even if it now has a builtin summary ↵Enrico Granata2012-03-021-8/+8
| | | | | | - having the std::vector test case deal with the fact that we now have said builtin summary llvm-svn: 151870
* (a) adding formatters for:Enrico Granata2012-03-022-1/+40
| | | | | | | | NSTimeZone and CFTimeZonRef SEL and related types CFGregorianDate llvm-svn: 151866
* (a) adding an introspection formatter for NS(Mutable)IndexSetEnrico Granata2012-03-012-4/+117
| | | | | | | | | (b) fixes and improvements to the formatters for NSDate and NSString (c) adding an introspection formatter for NSCountedSet (d) making the Objective-C formatters test cases pass on both 64 and 32 bit one of the test cases is marked as expected failure on i386 - support needs to be added to the LLDB core for it to pass llvm-svn: 151826
* 1) solving a bug where, after Jim's fixes to stack frames, synthetic ↵Enrico Granata2012-03-013-14/+21
| | | | | | | | | | | | | | | | | children were not recalculated when necessary, causing them to get out of sync with live data 2) providing an updated list of tagged pointers values for the objc_runtime module - hopefully this one is final 3) changing ValueObject::DumpValueObject to use an Options class instead of providing a bulky list of parameters to pass around this change had been laid out previously, but some clients of DumpValueObject() were still using the old prototype and some arguments were treated in a special way and passed in directly instead of through the Options class 4) providing new GetSummaryAsCString() and GetValueAsCString() calls in ValueObject that are passed a formatter object and a destination string and fill the string by formatting themselves using the formatter argument instead of the default for the current ValueObject 5) removing the option to have formats and summaries stick to a variable for the current stoppoint after some debate, we are going with non-sticky: if you say frame variable --format hex foo, the hex format will only be applied to the current command execution and not stick when redisplaying foo the other option would be full stickiness, which means that foo would be formatted as hex for its whole lifetime we are open to suggestions on what feels "natural" in this regard llvm-svn: 151801
* This commit:Enrico Granata2012-02-292-5/+146
| | | | | | | | | | | | | a) adds a Python summary provider for NSDate b) changes the initialization for ScriptInterpreter so that we are not passing a bulk of Python-specific function pointers around c) provides a new ScriptInterpreterObject class that allows for ref-count safe wrapping of scripting objects on the C++ side d) contains much needed performance improvements: 1) the pointer to the Python function generating a scripted summary is now cached instead of looked up every time 2) redundant memory reads in the Python ObjC runtime wrapper are eliminated 3) summaries now use the m_summary_str in ValueObject to store their data instead of passing around ( == copying) an std::string object e) contains other minor fixes, such as adding descriptive error messages for some cases of summary generation failure llvm-svn: 151703
* Reworking the ObjC formatters test case not to test everything in one huge ↵Enrico Granata2012-02-241-13/+97
| | | | | | code block - better for maintenance and debugging llvm-svn: 151390
* commenting parts of std::map test case which would make the test case fail ↵Enrico Granata2012-02-231-8/+20
| | | | | | when using TOT clang, but succeed on older compiler releases llvm-svn: 151309
* This patch provides a set of formatters for most of the commonly used Cocoa ↵Enrico Granata2012-02-231-0/+0
| | | | | | | | | | classes. The formatter for NSString is an improved version of the one previously shipped as an example, the others are new in design and implementation. A more robust and OO-compliant Objective-C runtime wrapper is provided for runtime versions 1 and 2 on 32 and 64 bit. The formatters are contained in a category named "AppKit", which is not enabled at startup. llvm-svn: 151301
* This patch provides a set of formatters for most of the commonly used Cocoa ↵Enrico Granata2012-02-234-415/+457
| | | | | | | | | | classes. The formatter for NSString is an improved version of the one previously shipped as an example, the others are new in design and implementation. A more robust and OO-compliant Objective-C runtime wrapper is provided for runtime versions 1 and 2 on 32 and 64 bit. The formatters are contained in a category named "AppKit", which is not enabled at startup. llvm-svn: 151299
* Add @expectedFailure decorator with radar number.Johnny Chen2012-02-221-0/+4
| | | | llvm-svn: 151212
* making it so that the std::map test case does a better job at checking for ↵Enrico Granata2012-02-182-12/+19
| | | | | | interference between expression parser and synthetic children; plus being more verbose in the comments llvm-svn: 150854
OpenPOWER on IntegriCloud