summaryrefslogtreecommitdiffstats
path: root/llvm/test/DebugInfo/Inputs
Commit message (Collapse)AuthorAgeFilesLines
* Migrate function attribute "no-frame-pointer-elim" to "frame-pointer"="all" ↵Fangrui Song2019-12-242-3/+3
| | | | as cleanups after D56351
* [llvm-symbolizer] Support debug file lookup using build IDPetr Hosek2019-12-041-0/+0
| | | | | | | | | | | | | | | | | | | Build ID is a protocol for looking up debug files that's already supported by various tools including debuggers. For example, when locating debug files, gdb would check the following directories: - /usr/lib/debug/.build-id/ab/cdef1234.debug - /usr/bin/ls.debug - /usr/bin/.debug/ls.debug - /usr/lib/debug/usr/bin/ls.debug llvm-symbolizer currently consults all of these except for build ID based one. This patch implements support for build ID lookup. The set of debug directories to search is specified by the new option: --debug-file-directory, whose name matches the debug-file-directory variable used by gdb for the same purpose. Differential Revision: https://reviews.llvm.org/D70759
* [DebugInfo] Support for debug_macinfo.dwo section in llvm and llvm-dwarfdump.Sourabh Singh Tomar2019-12-031-0/+0
| | | | | | | | | | | This patch adds support for debug_macinfo.dwo section[pre-standardized] to llvm and llvm-dwarfdump. Reviewers: probinson, dblaikie, aprantl, jini.susan.george, alok Differential Revision: https://reviews.llvm.org/D70705 Tags: #debug-info #llvm
* [DebugInfo] Add column info for inline sitesJonas Devlieghere2019-07-121-0/+1
| | | | | | | | | | | | The column field is missing for all inline sites, currently it's always zero. This changes populates DW_AT_call_column field for inline sites. Test case modified to cover this change. Patch by: Wenlei He Differential revision: https://reviews.llvm.org/D64033 llvm-svn: 365945
* [llvm-readobj] Change -long-option to --long-option in tests. NFCFangrui Song2019-05-011-1/+1
| | | | | | | | | | We use both -long-option and --long-option in tests. Switch to --long-option for consistency. In the "llvm-readelf" mode, -long-option is discouraged as it conflicts with grouped short options and it is not accepted by GNU readelf. While updating the tests, change llvm-readobj -s to llvm-readobj -S to reduce confusion ("s" is --section-headers in llvm-readobj but --symbols in llvm-readelf). llvm-svn: 359649
* [DebugInfo][llvm-symbolizer]Add some tests for edge cases when symbolizingJames Henderson2019-02-062-0/+6
| | | | | | | | | | | | This patch adds half a dozen new tests that test various edge cases in the behaviour of the symbolizer and DWARF data parsing. All of them test the current behaviour. Reviewed by: JDevlieghere, aprantl Differential Revision: https://reviews.llvm.org/D57741 llvm-svn: 353286
* [llvm-symbolizer][test] Extract tests from llvm-symbolizer.test and simplify ↵James Henderson2019-01-313-20/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | (#3) This is the fourth (and final for now) of a series of patches simplifying llvm-symbolizer tests. See r352752, r352753 and 352754 for the previous ones. This patch splits out several more distinct test cases from llvm-symbolizer.test into separate tests, and simplifies them in various ways including: 1) Building a test case for spaces in path from source, rather than using a pre-canned binary. This allows deleting of said binary and the source it was built from. 2) Switching to specifying addresses and objects directly on the command-line rather than via stdin. This also adds an explict test for the ability to specify a file and address as a line in stdin, since the majority of the tests have been migrated away from this approach, leaving this largely untested. Reviewed by: dblaikie Differential Revision: https://reviews.llvm.org/D57446 llvm-svn: 352756
* [llvm-symbolizer][test] Extract tests from llvm-symbolizer.test and simplify ↵James Henderson2019-01-311-18/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (#2) This is the third of a series of patches simplifying llvm-symbolizer tests. See r352752 and r352753 for the previous two. This patch splits out a number of distinct test cases from llvm-symbolizer.test into separate tests, and simplifies them in various ways including: 1) using --obj/positional arguments for the input file and addresses instead of stdin, 2) using runtime-generated inputs rather than a pre-canned binary, and 3) testing more specifically (i.e. checking only what is interesting to the behaviour changed in the original commit for that test case). This patch also removes the test case for using --obj. The tools/llvm-symbolizer/basic.s test already tests this case. Finally, this patch adds a simple test case to the demangle switch test case to show that demangling happens by default. See https://bugs.llvm.org/show_bug.cgi?id=40070#c1 for the motivation. Reviewed by: dblaikie Differential Revision: https://reviews.llvm.org/D57446 llvm-svn: 352754
* llvm-symbolizer: Extract individual test cases now that it's easier to use ↵David Blaikie2019-01-2417-97/+0
| | | | | | | | | | directly (without a piped input file) Pulling out the split-dwarf tests by way of example of how I think llvm-symbolizer should be tested going forward. Open to debate/discussion, though. llvm-svn: 352004
* Remove irrelevant references to legacy git repositories fromJames Y Knight2019-01-151-2/+2
| | | | | | | | | compiler identification lines in test-cases. (Doing so only because it's then easier to search for references which are actually important and need fixing.) llvm-svn: 351200
* Reapply: DebugInfo: Assume an absence of ranges or high_pc on a CU means the ↵David Blaikie2018-12-215-0/+0
| | | | | | | | | | | | | | | | | | | | | CU is empty (devoid of code addresses) Originally committed in r349333, reverted in r349353. GCC emitted these unconditionally on/before 4.4/March 2012 Clang emitted these unconditionally on/before 3.5/March 2014 This improves performance when parsing CUs (especially those using split DWARF) that contain no code ranges (such as the mini CUs that may be created by ThinLTO importing - though generally they should be/are avoided, especially for Split DWARF because it produces a lot of very small CUs, which don't scale well in a bunch of other ways too (including size)). The revert was due to a (Google internal) test that had some checked in old object files missing DW_AT_ranges. That's since been fixed. llvm-svn: 349968
* Revert "DebugInfo: Assume an absence of ranges or high_pc on a CU means the ↵Eric Liu2018-12-175-0/+0
| | | | | | | | | CU is empty (devoid of code addresses)" This reverts commit r349333. It caused internal test to fail. I have sent more information to the author. llvm-svn: 349353
* DebugInfo: Assume an absence of ranges or high_pc on a CU means the CU is ↵David Blaikie2018-12-175-0/+0
| | | | | | | | | | | | | | | | empty (devoid of code addresses) GCC emitted these unconditionally on/before 4.4/March 2012 Clang emitted these unconditionally on/before 3.5/March 2014 This improves performance when parsing CUs (especially those using split DWARF) that contain no code ranges (such as the mini CUs that may be created by ThinLTO importing - though generally they should be/are avoided, especially for Split DWARF because it produces a lot of very small CUs, which don't scale well in a bunch of other ways too (including size)). llvm-svn: 349333
* [DWARF] Make llvm-dwarfdump display location lists in a .dwp file correctly. ↵Wolfgang Pieb2018-10-191-0/+32
| | | | | | | | | | | | | Fixes PR38990. Considers the index when extracting location lists from a .dwp file. Majority of the patch by David Blaikie. Reviewers: dblaikie Differential revision: https://reviews.llvm.org/D53155 llvm-svn: 344807
* Revert "[DWARF] reposting r342048, which was reverted in r342056 due to ↵Alexander Kornienko2018-09-171-1/+1
| | | | | | | | | buildbot errors. Adjusted 2 test cases for ARM and darwin and fixed a bug with the original change in dsymutil." This reverts commit r342218. Due to a number of failures under TSAN. An isolated test case is being worked on. llvm-svn: 342399
* [DWARF] reposting r342048, which was reverted in r342056 due to buildbot Wolfgang Pieb2018-09-141-1/+1
| | | | | | | | errors. Adjusted 2 test cases for ARM and darwin and fixed a bug with the original change in dsymutil. llvm-svn: 342218
* Reverting r342048, which caused UBSan failures in dsymutil.Wolfgang Pieb2018-09-121-1/+1
| | | | llvm-svn: 342056
* [DWARF] Refactoring range list dumping to fold DWARF v4 functionality into ↵Wolfgang Pieb2018-09-121-1/+1
| | | | | | | | | | | | | v5 handling Eliminating some duplication of rangelist dumping code at the expense of some version-dependent code in dump and extract routines. Reviewer: dblaikie, JDevlieghere, vleschuk Differential revision: https://reviews.llvm.org/D51081 llvm-svn: 342048
* llvm-symbolizer: Fix bug related to TUs interfering with symbolizingDavid Blaikie2018-09-111-0/+0
| | | | | | | | | | | With the merge of TUs and CUs into a single container, some code that relied on the CU range having an ordered range of contiguous addresses (for locating a CU at a given offset) broke. But the units from debug_info (currently only CUs, but CUs and TUs in DWARFv5) are in a contiguous sub-range of that container - searching only through that subrange is still valid & so do that. llvm-svn: 341889
* [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label.Shiva Chen2018-05-092-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In order to set breakpoints on labels and list source code around labels, we need collect debug information for labels, i.e., label name, the function label belong, line number in the file, and the address label located. In order to keep these information in LLVM IR and to allow backend to generate debug information correctly. We create a new kind of metadata for labels, DILabel. The format of DILabel is !DILabel(scope: !1, name: "foo", file: !2, line: 3) We hope to keep debug information as much as possible even the code is optimized. So, we create a new kind of intrinsic for label metadata to avoid the metadata is eliminated with basic block. The intrinsic will keep existing if we keep it from optimized out. The format of the intrinsic is llvm.dbg.label(metadata !1) It has only one argument, that is the DILabel metadata. The intrinsic will follow the label immediately. Backend could get the label metadata through the intrinsic's parameter. We also create DIBuilder API for labels to be used by Frontend. Frontend could use createLabel() to allocate DILabel objects, and use insertLabel() to insert llvm.dbg.label intrinsic in LLVM IR. Differential Revision: https://reviews.llvm.org/D45024 Patch by Hsiangkai Wang. llvm-svn: 331841
* llvm-symbolizer: Handle function definitions nested within other functionsDavid Blaikie2018-05-011-0/+0
| | | | | | | | | | | | LLVM always puts function definition DIEs at the top level, but under some circumstances GCC does not (at least in this case with member functions of a function-local type). To ensure that doesn't appear as though the local type's member function is unduly inlined within the outer function - ensure the inline discovery DIE parent walk stops at the first DW_TAG_subprogram. llvm-svn: 331291
* [Debuginfo][COFF] Minimal serialization support for precompiled types recordsAlexandre Ganea2018-04-092-0/+0
| | | | | | | | | | | | | This change adds support for the LF_PRECOMP and LF_ENDPRECOMP records required to read/write Microsoft precompiled types .objs. See https://en.wikipedia.org/wiki/Precompiled_header#Microsoft_Visual_C_and_C++ This also adds handling for the .debug$P section, which is actually a .debug$T section in disguise, found only in precompiled .objs. Differential Revision: https://reviews.llvm.org/D45283 llvm-svn: 329613
* DebugInfo/llvm-symbolizer: Test symbolizing Split DWARF without addresses in ↵David Blaikie2018-02-092-0/+0
| | | | | | | | | the skeleton CU Identified in an llvm-dev discussion around DWARFUnit::collectAddressRanges llvm-svn: 324702
* [DebugInfo] Don't crash when given invalid DWARFv5 line table prologue.Jonas Devlieghere2018-01-051-0/+0
| | | | | | | | | | | | | This patch replaces an assertion with an explicit check for the validity of the FORM parameters. The assertion was triggered when the DWARFv5 line table contained a zero address size. This fixes OSS-Fuzz Issue 4644 https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=4644 Differential revision: https://reviews.llvm.org/D41615 llvm-svn: 321863
* [dwarfdump] Fix off-by-one bug in accelerator table extractor.Jonas Devlieghere2017-12-111-0/+0
| | | | | | | | | | | | | | | This fixes a bug where the verifier was complaining about empty accelerator tables. When the table is empty, its size is not a valid offset as it points after the end of the section. This patch also makes the extractor return llvm:Error instead of bool for better error reporting in the verifier. Differential revision: https://reviews.llvm.org/D41063 rdar://35932007 llvm-svn: 320399
* [NFC] Change the string offsets table tests to generate the object on the flyWolfgang Pieb2017-12-0916-1001/+0
| | | | | | | | which enables us to remove the test scripts and object files from the repository. https://reviews.llvm.org/D40914 llvm-svn: 320227
* [DwarfDump] -debug-line=offset applies to .dwo too.Paul Robinson2017-11-222-10/+0
| | | | llvm-svn: 318856
* Convert a dwarfdump test from checked-in binary to assembler source.Paul Robinson2017-11-072-261/+0
| | | | llvm-svn: 317612
* [DWARFv5] Support DW_FORM_strp in the .debug_line header.Paul Robinson2017-11-072-3/+7
| | | | | | | | Supporting this form in .debug_line.dwo will be done as a follow-up. Differential Revision: https://reviews.llvm.org/D33155 llvm-svn: 317607
* Update testcase that was XFAILed on Darwin for llvm-dwarfdump change.Adrian Prantl2017-09-131-1/+0
| | | | llvm-svn: 313209
* llvm-dwarfdump: automatically dump both regular and .dwo variant of sectionsAdrian Prantl2017-09-131-6/+2
| | | | | | | | | | | | 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
* Migrate llvm-symbolizer tests to not use %TDavid Blaikie2017-09-0813-4/+42
| | | | | | (context around the %T removal here: https://reviews.llvm.org/D35396 ) llvm-svn: 312828
* Revert "[Decompression] Fail gracefully when out of memory"Vedant Kumar2017-09-051-0/+0
| | | | | | | | | | | | | This reverts commit r312526. Revert "Fix test/DebugInfo/dwarfdump-decompression-invalid-size.test" This reverts commit r312527. It causes an ASan failure: http://lab.llvm.org:8080/green/job/clang-stage2-cmake-RgSan_check/4150 llvm-svn: 312582
* [Decompression] Fail gracefully when out of memoryJonas Devlieghere2017-09-051-0/+0
| | | | | | | | | | | | This patch adds failing gracefully when running out of memory when allocating a buffer for decompression. This provides a work-around for: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3224 Differential revision: https://reviews.llvm.org/D37447 llvm-svn: 312526
* [DebugInfo] - Fix for lld DWARF parsing of base address selection entries in ↵George Rimar2017-09-041-0/+0
| | | | | | | | | | | | | range lists. It solves issue of wrong section index evaluating for ranges when base address is used. Based on David Blaikie's patch D36097. Differential revision: https://reviews.llvm.org/D37214 llvm-svn: 312477
* [Object] Verify object sizes before handing out StringRefs pointing outBenjamin Kramer2017-08-311-0/+0
| | | | | | | | | of bounds. This can only happen on corrupt input. Found by OSS-FUZZ! https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3228 llvm-svn: 312235
* DebugInfo: Test & handle (differently) non-zero DW_AT_ranges_baseDavid Blaikie2017-08-023-7/+17
| | | | | | | | | Followup to r309570, fixing it slightly differently (ranges_base and addr_base should never be read from a DWO file - so there shouldn't be any issue with 'overriding' the values - conditionalize the code and assert that the values aren't being overriden). llvm-svn: 309879
* [DWARF] Fixing a bug with processing of DWARF v5 indexed strings in Mach-O ↵Wolfgang Pieb2017-07-132-0/+201
| | | | | | | | | | | objects. Code to convert MachO - specific section debug section names to standard DWARF v5 section names was in the wrong place. Differential Revision: https://reviews.llvm.org/D35321 llvm-svn: 307872
* [LLVM] Get rid of white spaces in file names in a DebugInfo test. NFCEric Liu2017-07-101-0/+0
| | | | | | | | | | | | Summary: White spaces in file names are causing Phabricator/SVN to crash. Reviewers: bkramer Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D35206 llvm-svn: 307550
* Revert "[lit] Clean output directories before running tests."Zachary Turner2017-06-309-16/+0
| | | | | | | | | This reverts commit da6318a92fba793e4f2447ec478b001392d57d43. This is causing failures on some build bots due to what appears to be some kind of lit ordering dependency. llvm-svn: 306833
* [lit] Clean output directories before running tests.Zachary Turner2017-06-309-0/+16
| | | | | | | | | | | | | | | | | | Presently lit leaks files in the tests' output directories. Specifically, if a test creates output files, lit makes no effort to remove them prior to the next test run. This is problematic because it leads to false positives whenever a test passes because stale files were present. In general it is a source of flakiness that should be removed. This patch addresses this by building the list of all test directories that are part of the current run set, and then deleting those directories and recreating them anew. This gives each test a clean baseline to start from. Differential Revision: https://reviews.llvm.org/D34732 llvm-svn: 306832
* [DWARF] Support for DW_FORM_strx3 and complete support for DW_FORM_strx{1,2,4}Wolfgang Pieb2017-06-212-2/+57
| | | | | | | | | | (consumer). Reviewer: aprantl Differential Revision: https://reviews.llvm.org/D34418 llvm-svn: 305944
* Removal of accidental duplication in test assembly file. NFC.Wolfgang Pieb2017-06-141-250/+0
| | | | llvm-svn: 305431
* Adding one test that I forgot to include with the commit for ↵Wolfgang Pieb2017-06-131-0/+0
| | | | | | | | https://reviews.llvm.org/D32779. NFC llvm-svn: 305261
* dwarfdump: Handle relocs to zlib (.zdebug*) compressed sectionsDavid Blaikie2017-06-102-1/+2
| | | | llvm-svn: 305152
* [DWARF] Adding support for the DWARF v5 string offsets table ↵Wolfgang Pieb2017-06-0613-0/+995
| | | | | | | | | | (consumer/reader part only). Reviewers: dblaikie, aprantl Differential Revision: https://reviews.llvm.org/D32779 llvm-svn: 304759
* DebugInfo: Add source code/build instructions for split-dwarf-dwp symbolizer ↵David Blaikie2017-05-271-0/+12
| | | | | | | | | test Addressing post-commit code review feedback from Paul Robinson on r303609. llvm-svn: 304080
* libDebugInfo: Support symbolizing using DWP filesDavid Blaikie2017-05-232-0/+0
| | | | llvm-svn: 303609
* libDebugInfo/DWARF: Apply relocations for debug_addr addresses in object filesDavid Blaikie2017-05-222-0/+0
| | | | | | | | | | | llvm-symbolizer would fail to symbolize addresses in unlinked object files when handling .dwo file data because the addresses would not be relocated in the same way as the ranges in the skeleton CU in the object file. Fix that so object files can be symbolized the same as executables. llvm-svn: 303532
* llvm-symbolizer: Support multiple CUs in a single DWO fileDavid Blaikie2017-05-202-0/+0
| | | | llvm-svn: 303482
OpenPOWER on IntegriCloud