summaryrefslogtreecommitdiffstats
path: root/llvm/test/tools/llvm-dwp
Commit message (Collapse)AuthorAgeFilesLines
* Remove some unnecessary REQUIRES: shell linesReid Kleckner2019-09-101-2/+0
| | | | | | | This means these tests will run on Windows. Replace one with UNSUPPORTED: system-windows. llvm-svn: 371473
* Replace 'REQUIRES: nozlib' with '!zlib' because we don't need two waysPaul Robinson2019-05-101-1/+1
| | | | | | to say the same thing. llvm-svn: 360455
* [llvm-dwp] Avoid writing the output dwp file when there is an errorJordan Rupprecht2019-02-121-0/+4
| | | | | | | | | | | | | | | | Summary: Use ToolOutputFile to clean up the output file unless dwp actually finishes successfully. Reviewers: dblaikie Reviewed By: dblaikie Subscribers: jdoerfert, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58130 llvm-svn: 353873
* [llvm-dwp] Abort when dwo_id is unsetJordan Rupprecht2019-02-124-2/+5
| | | | | | | | | | | | | | | | | | | Summary: An empty dwo_id indicates a degenerate .dwo file that should not have been generated in the first place. Instead of discovering this error later when merging with another degenerate .dwo file, print an error immediately when noticing an unset dwo_id, including the filename of the offending file. Test case created by compiling a trivial file w/ `-fno-split-dwarf-inlining -gmlt -gsplit-dwarf -c` prior to r353771 Reviewers: dblaikie Reviewed By: dblaikie Subscribers: jdoerfert, aprantl, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58085 llvm-svn: 353846
* [llvm-dwp] Clean up tests X86/*.testFangrui Song2018-09-076-15/+8
| | | | llvm-svn: 341688
* Reland rL341509: "[llvm-dwp] Use buffer_stream if output file is not ↵Fangrui Song2018-09-061-4/+2
| | | | | | | | | | seekable (e.g. "-")" It caused ambiguity between llvm::cl::Optional and llvm::Optional, which has been fixed by dropping `using namespace cl;` in favor of explicit cl:: qualified names. llvm-svn: 341586
* Revert rL341509 to fix massive failures on buildbotsMax Kazantsev2018-09-061-2/+4
| | | | llvm-svn: 341515
* [llvm-dwp] Fix `UN:` lines (supposed to be `RUN:`) in X86/simple.test and ↵Fangrui Song2018-09-061-8/+7
| | | | | | | | | | | | adjust check lines for TYPES: Reviewers: dblaikie, aprantl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D51704 llvm-svn: 341510
* [llvm-dwp] Use buffer_stream if output file is not seekable (e.g. "-")Fangrui Song2018-09-061-4/+2
| | | | | | | | | | Reviewers: dblaikie, pcc Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D51707 llvm-svn: 341509
* llvm-dwarfdump: automatically dump both regular and .dwo variant of sectionsAdrian Prantl2017-09-132-5/+4
| | | | | | | | | | | | Since users typically don't really care about the .dwo / non.dwo distinction, this patch makes it so dwarfdump --debug-<info,...> dumps .debug_info and (if available) also .debug_info.dwo. This simplifies the command line interface (I've removed all dwo-specific dump options) and makes the tool friendlier to use. Differential Revision: https://reviews.llvm.org/D37771 llvm-svn: 313207
* llvm-dwarfdump: Make -brief the default and add a -verbose option instead.Adrian Prantl2017-09-117-11/+11
| | | | | | Differential Revision: https://reviews.llvm.org/D37717 llvm-svn: 312972
* [llvm-dwp] Implement -e optionAlexander Shaposhnikov2017-09-028-0/+97
| | | | | | | | | | | | | | | The binutils utility dwp has an option "-e" https://gcc.gnu.org/wiki/DebugFissionDWP to specify an executable/library to get the list of *.dwo files from it. This option is particularly useful when someone runs the tool manually outside of a build system. This diff adds an implementation of "-e" to llvm-dwp. Test plan: make check-all Differential revision: https://reviews.llvm.org/D37371 llvm-svn: 312409
* [llvm] Get rid of "%T" expansionsKuba Mracek2017-08-151-2/+2
| | | | | | | | | | The %T lit expansion expands to a common directory shared between all the tests in the same directory, which is unexpected and unintuitive, and more importantly, it's been a source of subtle race conditions and flaky tests. In https://reviews.llvm.org/D35396, it was agreed that it would be best to simply ban %T and only keep %t, which is unique to each test. When a test needs a temporary directory, it can just create one using mkdir %t. This patch removes %T in llvm. Differential Revision: https://reviews.llvm.org/D36495 llvm-svn: 310953
* [llvm-dwp] - Reuse object::Decompressor classGeorge Rimar2017-01-132-2/+2
| | | | | | | | One more place where Decompressor class can be reused. Differential revision: https://reviews.llvm.org/D28679 llvm-svn: 291906
* dwarfdump: -summarize-types: print a short summary (unqualified type name, ↵David Blaikie2016-10-181-3/+3
| | | | | | | | | | hash, length) of type units rather than dumping contents This is just a quick utility handy for getting rough summaries of types in a given object or dwo file. I've been using it to investigate the amount of type info redundancy across a project build, for example. llvm-svn: 284537
* llvm-dwp: More error handling around invalid compressed sectionsDavid Blaikie2016-05-233-1/+3
| | | | llvm-svn: 270466
* llvm-dwp: Add error handling for multiple type sections in a dwp file.David Blaikie2016-05-172-0/+3
| | | | llvm-svn: 269851
* llvm-dwp: Provide error handling for invalid string field formsDavid Blaikie2016-05-172-0/+3
| | | | | | | | | | This diagnostic could be improved by adding the name of the input file containing the invalid data and/or some information about how to identify the specific offending attribute/tag in the input. But that's not an immediate priority as these corner cases of invalid input shouldn't come up too often. llvm-svn: 269727
* llvm-dwp: Add error handling for invalid (non-CU) top level tag in ↵David Blaikie2016-05-162-0/+3
| | | | | | | | | | debug_info.dwo The diagnostic could be improved a bit to include information about which input file had the mistake (& which unit (counted, since the name of the unit won't be accessible) within the input). llvm-svn: 269723
* llvm-dwp: Add .test files missing from r269339David Blaikie2016-05-162-0/+6
| | | | llvm-svn: 269705
* llvm-dwp: Streamline duplicate DWO ID diagnostic handlingDavid Blaikie2016-05-161-6/+6
| | | | | | | | Actually use the error return path rather than printing the duplicate information then a separate error. But also just tidy up/deduplicate some of the code for generating the diagnostic text. llvm-svn: 269692
* llvm-dwp: Use llvm::Error to improve diagnostic quality/error handling in ↵David Blaikie2016-05-127-0/+10
| | | | | | llvm-dwp llvm-svn: 269339
* llvm-dwp: Handle GCC's use of multiple debug_types.dwo sections in a single ↵David Blaikie2016-04-051-0/+9
| | | | | | | | .dwo file (also includes the .test file missing from my previous commit, r265452) llvm-svn: 265457
* llvm-dwp: Handle dwo files produced by GCCDavid Blaikie2016-04-051-0/+0
| | | | | | | To start with, handle DW_FORM_string names. Follow up commit will handle the interesting quirk with type units I was originally aiming for here. llvm-svn: 265452
* llvm-dwp: Include the dwo name (if available) when diagnosing duplicate CU ↵David Blaikie2016-03-264-9/+18
| | | | | | | | | | | | IDs from dwp input files If you're building dwps from other dwps, it can be hard to track down a duplicate CU ID if it comes from two compilations of the same file in different modes, etc. By including the .dwo path (which is hopefully more unique than the file path) it can help track down where the duplicates came from. llvm-svn: 264520
* llvm-dwp: Coalesce code for reading the CU's DW_AT_GNU_dwo_id and DW_AT_nameDavid Blaikie2016-03-241-2/+2
| | | | | | | | Going to be reading the DW_AT_GNU_dwo_name shortly as well, and there was already enough duplication here that it was worth refactoring rather than adding even more. llvm-svn: 264350
* llvm-dwp: provide diagnostics for duplicate DWO IDsDavid Blaikie2016-02-264-0/+18
| | | | | | | | | | | | | | These diagnostics aren't perfect - in the case of merging several dwos into dwps and those dwps into more dwps - just getting the message about the original source file name might not be much help (since it's the same in both dwos, by definition - but doesn't tell you which chain of dwps to backtrack) It might be worth adding the DW_AT_dwo_id to the split debug info to improve the diagnostic experience - might help track down the duplicates better. llvm-svn: 261988
* llvm-dwp: Support empty .dwo filesDavid Blaikie2016-02-262-0/+8
| | | | | | | | | Though a bit odd, this is handy for a few reasons - for example, in a build system that wants consistent input/output of build steps, but where split-dwarf might be overriden/disabled by the user on a per-file basis. llvm-svn: 261987
* llvm-dwp: Don't test compression when zlib isn't availableDavid Blaikie2016-02-191-0/+2
| | | | llvm-svn: 261298
* llvm-dwp: Support compressed inputDavid Blaikie2016-02-192-0/+17
| | | | llvm-svn: 261296
* llvm-dwp: Support for type units when merging DWPs into larger DWPsDavid Blaikie2016-02-171-0/+3
| | | | llvm-svn: 261072
* [llvm-dwp] Merge cu_index from DWPsDavid Blaikie2016-02-063-0/+48
| | | | | | This is almost feature complete - just missing tu_index merging now. llvm-svn: 259971
* [llvm-dwp] Deduplicate type unitsDavid Blaikie2015-12-143-0/+35
| | | | | | | | It's O(N^2) because it does a simple walk through the existing types to find duplicates, but that will be fixed in a follow-up commit to use a mapping data structure of some kind. llvm-svn: 255482
* [llvm-dwp] Remove some unused test codeDavid Blaikie2015-12-142-5/+0
| | | | llvm-svn: 255481
* [llvm-dwp] Restructure inputs for test case so they're all grouped togetherDavid Blaikie2015-12-075-2/+2
| | | | llvm-svn: 254922
* [llvm-dwp] Add coverage for both the presence and absence of type units, and ↵David Blaikie2015-12-053-23/+35
| | | | | | fix/remove the emission of a broken tu_index when no type units are present llvm-svn: 254833
* [llvm-dwp] Fix the type_units.test since I renamed its inputs as wellDavid Blaikie2015-12-051-1/+1
| | | | llvm-svn: 254830
* [llvm-dwp] Rename the sufficiently-modified test to reflect it's non-simplicityDavid Blaikie2015-12-055-0/+0
| | | | llvm-svn: 254829
* [llvm-dwp] Support debug_tu_indexDavid Blaikie2015-12-053-13/+38
| | | | llvm-svn: 254827
* [llvm-dwp] Remove some out of date commentsDavid Blaikie2015-12-041-2/+0
| | | | llvm-svn: 254772
* [llvm-dwp] Implement the required on-disk probed hash tableDavid Blaikie2015-12-041-2/+2
| | | | llvm-svn: 254770
* [llvm-dwp] Include the debug_line.dwo sectionDavid Blaikie2015-12-041-3/+3
| | | | | | | | | | | | This probably shouldn't be generated in the .dwo file for CUs, only for TUs, but it's in the sample .dwos (generated by clang) so dwp should reflect that. Arguably the DWP tool could be smart enough to know that the CUs shouldn't need a debug_line.dwo section and skip that even when it's legitimately generated for TUs, but that's a bit more off-book. llvm-svn: 254767
* [llvm-dwp] Retrieve the DWOID from the CU for the cu_index entryDavid Blaikie2015-12-041-2/+4
| | | | llvm-svn: 254731
* [llvm-dwp] Include only the non-empty columns in the cu_indexDavid Blaikie2015-12-021-1/+5
| | | | llvm-svn: 254555
* [llvm-dwp] Emit a rather fictional debug_cu_indexDavid Blaikie2015-12-021-6/+7
| | | | | | | | | | | | | | This is very rudimentary support for debug_cu_index, but it is enough to allow llvm-dwarfdump to find the offsets for contributions and correctly dump debug_info. It will need to actually find the real signature of the unit and build the real hash table with the right number of buckets, as per the DWP specification. It will also need to be expanded to cover the tu_index as well. llvm-svn: 254489
* [llvm-dwp] Deduplicate strings in the debug_str.dwo sectionDavid Blaikie2015-12-011-4/+2
| | | | | | | Also, ensure that references to those strings in debug_str_offsets.dwo correctly refer to the deduplicated strings. llvm-svn: 254441
* [llvm-dwp] Correctly update debug_str_offsets.dwo when linking dwo filesDavid Blaikie2015-12-011-3/+3
| | | | | | | | | | This doesn't deduplicate strings in the debug_str section, nor does it properly wire up the index so that debug_info can /find/ these strings, but it does correct the str_offsets specifically. Follow up patches to address those related/next issues. llvm-svn: 254431
* [llvm-dwp] Initial partial prototypeDavid Blaikie2015-12-016-0/+67
This just concatenates the common DWP sections without doing any of the fancy DWP things like: 1) update str_offsets 2) deduplicating strings 3) merging/creating cu/tu_index Patches for these will follow shortly. (also not sure about target triple/object file type for this tool - do I really need a whole triple just to write an object file that contains purely static/hardcoded bytes in each section? & I guess I should just pick it based on the first input, maybe, rather than hardcoding for now - but we only produce .dwo on ELF platforms with objcopy for now anyway) llvm-svn: 254355
OpenPOWER on IntegriCloud