- May 18, 2018
-
-
Wolfgang Pieb authored
llvm-svn: 332766
-
Wolfgang Pieb authored
llvm-svn: 332762
-
Wolfgang Pieb authored
extract DWARF v5 encoded rangelists. Reviewer: JDevlieghere Differential Revision: https://reviews.llvm.org/D45549 llvm-svn: 332759
-
- May 14, 2018
-
-
Paul Robinson authored
Extract information related to a "unit header" from DWARFUnit into a new DWARFUnitHeader class, and add a DWARFUnit member for the header. This is one step in the direction of allowing type units in the .debug_info section for DWARF v5. Differential Revision: https://reviews.llvm.org/D46707 llvm-svn: 332289
-
- May 10, 2018
-
-
Wolfgang Pieb authored
length excluding the table header. Instead it must encode the contribution length minus the length field itself. Reviewer: JDevliegehere Differential Revision: https://reviews.llvm.org/D45922 llvm-svn: 332030
-
- May 01, 2018
-
-
David Blaikie authored
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
-
- Apr 15, 2018
-
-
Jonas Devlieghere authored
Use the convenience methods from WithColor to consistently print errors and warnings in libDebugInfo. llvm-svn: 330092
-
- Mar 21, 2018
-
-
Rafael Espindola authored
This is mostly just plumbing to get a DWARFDataExtractor where we compute abbr_offset so we can use getRelocatedValue. This is part of PR36793. llvm-svn: 328154
-
- Mar 14, 2018
-
-
Pavel Labath authored
Summary: This patch replaces the two switches which are deducing the size of various forms with a single implementation. I have put the new implementation into BinaryFormat, to avoid introducing dependencies between the two independent libraries (DebugInfo and CodeGen) that need this functionality. Reviewers: aprantl, JDevlieghere, dblaikie Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D44418 llvm-svn: 327486
-
- Feb 13, 2018
-
-
David Blaikie authored
Revert "Rewrite the cached map used for locating the most precise DIE among inlined subroutines for a given address." Seeing some inlining missing in internal uses of symbolizer. I'll work on a reproduction, tests, improvements & recommit as soon as possible. (Chandler would like it to be known that this improvement did make check-llvm 4x faster... - so there's certainly some fairly good motivation to push on fixing/figuring this out & getting it back in) This reverts commit r321345. llvm-svn: 324981
-
- Jan 29, 2018
-
-
Paul Robinson authored
llvm-svn: 323701
-
- Jan 25, 2018
-
-
Paul Robinson authored
This form is like DW_FORM_strp, but points to .debug_line_str instead of .debug_str as the string section. It's intended to be used from the line-table header, and allows string-pooling of directory and filenames across compilation units. Differential Revision: https://reviews.llvm.org/D42553 llvm-svn: 323476
-
- Dec 22, 2017
-
-
Chandler Carruth authored
inlined subroutines for a given address. This is essentially the hot path of llvm-symbolizer when extracting inlined frames during symbolization. Previously, we would read every subprogram and every inlined subroutine, building a std::map across the entire PC space to the best DIE, and then do only a handful of queries as we symbolized a backtrace. A huge fraction of the time was spent building the map itself. This patch changes it two a two-level system. First, we just build a map from PC-interval to DWARF subprograms. These are required to be disjoint and so constructing this is pretty easy. Second, we build a map *just* for the inlined subroutines within the subprogram containing the query address. This allows us to look at far fewer DIEs and build a *much* smaller set of cached maps in the llvm-symbolizer case where only a few address get symbolized during the entire run. It also builds both interval maps in a very different way. It constructs a single flat vector of pairs that maps from offset -> index. The indices point into collections of DIE objects, but can also be "tombstones" (-1) to mark gaps. In the case of subprograms, this mostly just simplifies the data structure a bit. For inlined subroutines, because we carefully split them as we build the map, we end up in many cases having no holes and not having to store both start and stop offsets. Finally, the PC ranges for the inlined subroutines are compressed into 32-bits by making them relative to the base PC of the outer subprogram. This means that if you have a single function body with over 2gb of executable code in it, we will stop mapping address past the first 2gb of that function into inlined subroutines and just give you the subprogram. This doesn't seem like a problem. ;] All of this combines to make llvm-symbolizer *well* over 2x faster for symbolizing backtraces out of LLVM's unittests. Death-test heavy unit tests are running >2x faster. I'm still going to look at completely disabling symbolization there, but figured while I had a good benchmark we should make symbolization a bit better. Sadly, the logic to build the flat interval map for the inlined subroutines is fairly complex. I'm not super happy about this and welcome any simplifying suggestions. Huge thanks to Dave Blaikie who helped walk me through what the various things I needed to do in DWARF to make this work. Differential Revision: https://reviews.llvm.org/D40987 llvm-svn: 321345
-
- Dec 21, 2017
-
-
Wolfgang Pieb authored
Reorganizes the DWARF consumer to derive the string offsets table contribution's format from the contribution header instead of (incorrectly) from the unit's format. Reviewers: JDevliegehere, aprantl Differential Revision: https://reviews.llvm.org/D41146 llvm-svn: 321295
-
- Oct 25, 2017
-
-
Jonas Devlieghere authored
Add the option to lookup an address in the debug information and print out the file, function, block and line table details. Differential revision: https://reviews.llvm.org/D38409 llvm-svn: 316619
-
George Rimar authored
This fixes possible out of bound access in DWARFDie::getFirstChild() which might happen when .debug_info section is corrupted, like shown in testcase. Differential revision: https://reviews.llvm.org/D39185 llvm-svn: 316566
-
- Oct 03, 2017
-
-
Hans Wennborg authored
The test fails on Linux; see follow-up email on the llvm-commits list. > Add the option to lookup an address in the debug information and print > out the file, function, block and line table details. > > Differential revision: https://reviews.llvm.org/D38409 This also reverts the follow-up r314818: > [test] Fix llvm-dwarfdump/cmdline.test > > Fixes test/tools/llvm-dwarfdump/cmdline.test llvm-svn: 314825
-
Jonas Devlieghere authored
Add the option to lookup an address in the debug information and print out the file, function, block and line table details. Differential revision: https://reviews.llvm.org/D38409 llvm-svn: 314817
-
- Sep 19, 2017
-
-
David Blaikie authored
When symbolizing large binaries, parsing every CU in a DWP file is a significant performance penalty. Instead, use the index to only load the CUs that are needed. llvm-svn: 313659
-
David Blaikie authored
This speeds up dumping specific DIEs by not parsing abbreviations for units that are not used. (this is also handy to have in eventually to speed up llvm-symbolizer for .dwp files, where parsing most of the DWP file can be avoided by using the index) llvm-svn: 313635
-
- Sep 04, 2017
-
-
George Rimar authored
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
-
- Aug 02, 2017
-
-
David Blaikie authored
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
-
- Aug 01, 2017
-
-
Benjamin Kramer authored
llvm-svn: 309683
-
- Jul 31, 2017
-
-
Benjamin Kramer authored
DIEs are lazily deserialized so it's possible that the DWO CU is created before the DIE is parsed. DWO shares .debug_addr and .debug_ranges with the object file so overwriting the offset with 0 will make the CU unusable. No test case because I couldn't get clang to emit a non-zero range base. llvm-svn: 309570
-
- Jul 20, 2017
-
-
Rafael Espindola authored
This changes DwarfContext to delegate to DwarfObject instead of having pure virtual methods. With this DwarfContextInMemory is replaced with an implementation of DwarfObject that is local to a .cpp file. llvm-svn: 308543
-
- Jun 29, 2017
-
-
Paul Robinson authored
Requires callers to directly associate relocations with a DataExtractor used to read data from a DWARF section, which helps a callee not make assumptions about which section it is reading. This is the next step in reducing DWARFFormValue's dependence on DWARFUnit. Differential Revision: https://reviews.llvm.org/D34704 llvm-svn: 306699
-
- Jun 27, 2017
-
-
Paul Robinson authored
do the indirection and relocation all in the same method. llvm-svn: 306418
-
- Jun 26, 2017
-
-
Paul Robinson authored
Some forms have sizes that depend on the DWARF version, DWARF format (32/64-bit), or the size of an address. Collect these into a struct to simplify passing them around. Require callers to provide one when they query a form's size. Differential Revision: http://reviews.llvm.org/D34570 llvm-svn: 306315
-
- Jun 23, 2017
-
-
Eugene Zelenko authored
[DebugInfo] Fix some Clang-tidy modernize-use-using and Include What You Use warnings; other minor fixes (NFC). llvm-svn: 306169
-
- Jun 06, 2017
-
-
Chandler Carruth authored
I did this a long time ago with a janky python script, but now clang-format has built-in support for this. I fed clang-format every line with a #include and let it re-sort things according to the precise LLVM rules for include ordering baked into clang-format these days. I've reverted a number of files where the results of sorting includes isn't healthy. Either places where we have legacy code relying on particular include ordering (where possible, I'll fix these separately) or where we have particular formatting around #include lines that I didn't want to disturb in this patch. This patch is *entirely* mechanical. If you get merge conflicts or anything, just ignore the changes in this patch and run clang-format over your #include lines in the files. Sorry for any noise here, but it is important to keep these things stable. I was seeing an increasing number of patches with irrelevant re-ordering of #include lines because clang-format was used. This patch at least isolates that churn, makes it easy to skip when resolving conflicts, and gets us to a clean baseline (again). llvm-svn: 304787
-
Wolfgang Pieb authored
Reviewers: dblaikie, aprantl Differential Revision: https://reviews.llvm.org/D32779 llvm-svn: 304759
-
- May 23, 2017
-
-
David Blaikie authored
llvm-svn: 303609
-
David Blaikie authored
Sorry for the bot noise. llvm-svn: 303592
-
David Blaikie authored
NFC, just an optimization. Will be building on this for DWP support shortly. llvm-svn: 303591
-
- May 22, 2017
-
-
David Blaikie authored
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
-
- May 20, 2017
-
-
David Blaikie authored
llvm-svn: 303482
-
- May 16, 2017
-
-
George Rimar authored
Recommit of r303159 "[DWARF] - Use DWARFAddressRange struct instead of uint64_t pair for DWARFAddressRangesVector" All places were shitched to use DWARFAddressRange now. Suggested during review of D33184. llvm-svn: 303163
-
- Apr 24, 2017
-
-
George Rimar authored
I found this when investigated "Bug 32319 - .gdb_index is broken/incomplete" for LLD. When we have object file with .debug_ranges section it may be filled with zeroes. Relocations are exist in file to relocate this zeroes into real values later, but until that a pair of zeroes is treated as terminator. And DWARF parser thinks there is no ranges at all when I am trying to collect address ranges for building .gdb_index. Solution implemented in this patch is to take relocations in account when parsing ranges. Differential revision: https://reviews.llvm.org/D32228 llvm-svn: 301170
-
- Apr 19, 2017
-
-
-
Dehao Chen authored
Summary: In the current implementation, to find inline stack for an address incurs expensive linear search in 2 places: * linear search for the top-level DIE * recursive linear traverse the DIE tree to find the path to the leaf DIE In this patch, a map is built from address to its corresponding leaf DIE. The inline stack is built by traversing from the leaf DIE up to the root DIE. This speeds up batch symbolization by ~10X without noticible memory overhead. Reviewers: dblaikie Reviewed By: dblaikie Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D32177 llvm-svn: 300742
-