aboutsummaryrefslogtreecommitdiffstats
path: root/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Extraneous whitespace and 80-col.Eric Christopher2011-12-161-3/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@146780 91177308-0d34-0410-b5e6-96231b3b80d8
* Add inline subprogram names to the name lookup table since they mayEric Christopher2011-12-041-0/+4
| | | | | | not get there any other way. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145789 91177308-0d34-0410-b5e6-96231b3b80d8
* Move global variables in TargetMachine into new TargetOptions class. As an APINick Lewycky2011-12-021-1/+1
| | | | | | | | | | | | | change, now you need a TargetOptions object to create a TargetMachine. Clang patch to follow. One small functionality change in PTX. PTX had commented out the machine verifier parts in their copy of printAndVerify. That now calls the version in LLVMTargetMachine. Users of PTX who need verification disabled should rely on not passing the command-line flag to enable it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145714 91177308-0d34-0410-b5e6-96231b3b80d8
* The dwarf standard says that the only differences between a out-of-lineRafael Espindola2011-11-121-0/+7
| | | | | | | | | | | | | | instance and a concrete inlined instance are the use of DW_TAG_subprogram instead of DW_TAG_inlined_subroutine and the who owns the tree. We were also omitting DW_AT_inline from the abstract roots. To fix this, make sure we mark abstract instance roots with DW_AT_inline even when we have only out-of-line instances referring to them with DW_AT_abstract_origin. FileCheck is not a very good tool for tests like this, maybe we should add a -verify mode to llvm-dwarfdump. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144441 91177308-0d34-0410-b5e6-96231b3b80d8
* Check in getOrCreateSubprogramDIE if a declaration exists and if so outputRafael Espindola2011-11-101-12/+0
| | | | | | | | it first. This is a more general fix to pr11300. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144324 91177308-0d34-0410-b5e6-96231b3b80d8
* Make types and namespaces take multiple DIEs for the accelerator tablesEric Christopher2011-11-101-8/+12
| | | | | | as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144319 91177308-0d34-0410-b5e6-96231b3b80d8
* Rework adding function names to the dwarf accelerator tables, allowEric Christopher2011-11-101-67/+71
| | | | | | multiple dies per function and support C++ basenames. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144304 91177308-0d34-0410-b5e6-96231b3b80d8
* Add comments.Benjamin Kramer2011-11-091-1/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144194 91177308-0d34-0410-b5e6-96231b3b80d8
* Take advantage of the zero byte in StringMap when emitting dwarf stringpool ↵Benjamin Kramer2011-11-091-2/+3
| | | | | | entries. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144184 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the pubnames section, no one consumes it.Eric Christopher2011-11-091-58/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144169 91177308-0d34-0410-b5e6-96231b3b80d8
* Also add the linkage name to the name accelerator tables if it existsEric Christopher2011-11-081-2/+14
| | | | | | and is different than the normal name. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144130 91177308-0d34-0410-b5e6-96231b3b80d8
* Add the base ObjC method name to the names lookup table as well.Eric Christopher2011-11-081-0/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144105 91177308-0d34-0410-b5e6-96231b3b80d8
* Add all completed and named types to the dwarf type accelerator tables.Eric Christopher2011-11-071-2/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144027 91177308-0d34-0410-b5e6-96231b3b80d8
* Use StringRef::startswith to do some string comparisons.Eric Christopher2011-11-071-5/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143982 91177308-0d34-0410-b5e6-96231b3b80d8
* Allow for the case where the name of the subprogram is "".Eric Christopher2011-11-071-0/+1
| | | | | | Fixes a self-host error. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143970 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove unnecessary addition to API. Replace with something much simpler.Eric Christopher2011-11-071-8/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143925 91177308-0d34-0410-b5e6-96231b3b80d8
* Add the support code to enable the dwarf accelerator tables. Upcoming patchesEric Christopher2011-11-071-0/+168
| | | | | | | | to fix the types section (all types, not just global types), and testcases. The code to do the final emission is disabled by default. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143923 91177308-0d34-0410-b5e6-96231b3b80d8
* Expose a way to get the beginning of the dwarf string section.Eric Christopher2011-11-071-12/+19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143920 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix up comment.Eric Christopher2011-11-071-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143919 91177308-0d34-0410-b5e6-96231b3b80d8
* Emit declarations before definitions if they are available. This causes ↵Rafael Espindola2011-11-041-6/+18
| | | | | | | | DW_AT_specification to point back in the file in the included testcase. Fixes PR11300. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143726 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't emit a directory entry for the value in DW_AT_comp_dir, that is alwaysNick Lewycky2011-11-021-4/+8
| | | | | | | implied by directory index zero. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143570 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach our Dwarf emission to use the string pool.Nick Lewycky2011-10-271-6/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143097 91177308-0d34-0410-b5e6-96231b3b80d8
* Reflow lines, fix comments for doxygen style, fix whitespace. No functionalityNick Lewycky2011-10-261-15/+11
| | | | | | | change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143074 91177308-0d34-0410-b5e6-96231b3b80d8
* Minor style cleanup, no functionality change.Nick Lewycky2011-10-171-3/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142307 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for a new extension to the .file directive:Nick Lewycky2011-10-171-15/+13
| | | | | | | | | | | .file filenumber "directory" "filename" This removes one join+split of the directory+filename in MC internals. Because bitcode files have independent fields for directory and filenames in debug info, this patch may change the .o files written by existing .bc files. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142300 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a new wrapper node for a DILexicalBlock that encapsulates it and aEric Christopher2011-10-111-0/+4
| | | | | | | | | | | | | file. Since it should only be used when necessary propagate it through the backend code generation and tweak testcases accordingly. This helps with code like in clang's test/CodeGen/debug-info-line.c where we have multiple #line directives within a single lexical block and want to generate only a single block that contains each file change. Part of rdar://10246360 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141729 91177308-0d34-0410-b5e6-96231b3b80d8
* Typo.Eric Christopher2011-10-031-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141004 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not use named md nodes to track variables that are completely optimized. ↵Devang Patel2011-08-191-36/+23
| | | | | | This does not scale while doing LTO with debug info. New approach is to include list of variables in the subprogram info directly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138145 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate unnecessary forwarding function.Devang Patel2011-08-181-16/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138006 91177308-0d34-0410-b5e6-96231b3b80d8
* Until now all debug info MDNodes referred to a root MDNode, a compile unit. ↵Devang Patel2011-08-161-91/+82
| | | | | | | | | | This simplified handling of these needs in dwarf writer. However, one side effect of this is that during link time optimization all these MDNodes are _not_ uniqued. In other words there will be N number of MDNodes describing "int", "char" and all other types, which would suddenly grow when each object file starts using libraries like STL. MDNodes graph structure such that compiler unit keeps track of important MDNodes and update dwarf writer to process mdnodes top-down instead of bottom up. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137778 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove unnecessary version check.Devang Patel2011-08-161-2/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137728 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactor.Devang Patel2011-08-151-49/+60
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137689 91177308-0d34-0410-b5e6-96231b3b80d8
* Continue to hoist uses of getCompileUnit() up. The goal is to get rid of ↵Devang Patel2011-08-151-19/+22
| | | | | | uses of getCompileUnit(). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137683 91177308-0d34-0410-b5e6-96231b3b80d8
* This is somewhat déjà-vu, but avoid using getCompileUnit() as much as ↵Devang Patel2011-08-151-11/+11
| | | | | | possible. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137668 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactor. Variables are part of compile unit so let CompileUnit create new ↵Devang Patel2011-08-151-122/+17
| | | | | | variable. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137663 91177308-0d34-0410-b5e6-96231b3b80d8
* There is no need to maintain a set to keep track of variables that use ↵Devang Patel2011-08-151-4/+2
| | | | | | location expressions. In such cases, AT_location attribute's value will be a label. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137659 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix warning.Devang Patel2011-08-151-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137658 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify. Let DbgVariable keep track of variable's DBG_VALUE machine ↵Devang Patel2011-08-151-39/+16
| | | | | | instruction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137656 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify mapping to variable from its abstract variable info.Devang Patel2011-08-151-24/+14
| | | | | | | When a variable is inlined multiple places, abstract variable keeps name, location, type etc.. info and all other concreate instances of the variable directly refers to abstract variable. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137637 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactor.Devang Patel2011-08-151-5/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137632 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactor.Devang Patel2011-08-151-14/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137631 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactor. Global variables are part of compile unit so let CompileUnit ↵Devang Patel2011-08-151-129/+2
| | | | | | create new global variable. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137621 91177308-0d34-0410-b5e6-96231b3b80d8
* Refactor. A subprogram is part of compile unit so let CompileUnit construct ↵Devang Patel2011-08-151-107/+8
| | | | | | new subprogram. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137618 91177308-0d34-0410-b5e6-96231b3b80d8
* Use ArrayRef.Devang Patel2011-08-121-6/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137485 91177308-0d34-0410-b5e6-96231b3b80d8
* Plug a memory leak.Benjamin Kramer2011-08-111-3/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137321 91177308-0d34-0410-b5e6-96231b3b80d8
* Stay within 80 columns.Devang Patel2011-08-101-18/+28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137283 91177308-0d34-0410-b5e6-96231b3b80d8
* Distinguish between two copies of one inlined variable. Take 2.Devang Patel2011-08-101-3/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137253 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert unintentional parts of previous check-in.Devang Patel2011-08-101-5/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137249 91177308-0d34-0410-b5e6-96231b3b80d8
* Start using LexicalScopes utility. No intetional functionality change.Devang Patel2011-08-101-488/+101
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137246 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify by creating parent first.Devang Patel2011-08-081-19/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137056 91177308-0d34-0410-b5e6-96231b3b80d8