summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGDebugInfo.h
Commit message (Collapse)AuthorAgeFilesLines
...
* [Layering] Update include for the move of DIBuilder.h to the IR libraryChandler Carruth2014-03-061-1/+1
| | | | | | in LLVM r203038. llvm-svn: 203039
* [Modules] Update to reflect ValueHandle moving to the IR library in LLVMChandler Carruth2014-03-041-1/+1
| | | | | | r202821. llvm-svn: 202822
* DebugInfo: Emit only the declaration of a class template that has an ↵David Blaikie2014-03-031-0/+2
| | | | | | | | | | | | | | | | | | | | | | | explicit instantiation declaration (& always emit such a type when there's an explicit instantiation definition) We should only have this optimization fire when the explicit instantiation definition would cause at least one member function to be emitted, thus ensuring that even a compiler not performing this optimization would still emit the full type information elsewhere. But we should also pessimize output still by always emitting the definition when the explicit instantiation definition appears so that at some point in the future we can depend on that information even when no code had to be emitted in that TU. (this shouldn't happen very often, since people mostly use explicit spec decl/defs to reduce code size - but perhaps one day they could use it to explicitly reduce debug info size too) This was worth about 2% for Clang and LLVM - so not a huge win, but a win. It looks really great for simple STL programs (include <string> and just declare a string - 14k -> 1.4k of .dwo) llvm-svn: 202769
* Debug info: Refactor NoLocation and ArtificialLocation to use a common baseAdrian Prantl2014-01-171-11/+18
| | | | | | | | | class and use it pervasively to restore debug locations. Fixes an interaction between cleanup and EH that caused the location to not be restored properly after emitting a landing pad. rdar://problem/15208190 llvm-svn: 199444
* Revert "Debug info: Ensure that the last stop point in a function is still ↵Adrian Prantl2014-01-071-7/+1
| | | | | | | | within" This reverts commit r198461. llvm-svn: 198714
* Revert "Debug info: Implement a cleaner version of r198461. For symmetry with"Adrian Prantl2014-01-071-1/+5
| | | | | | This reverts commit 198699 so we can get a cleaner patch. llvm-svn: 198713
* Debug info: Implement a cleaner version of r198461. For symmetry withAdrian Prantl2014-01-071-5/+1
| | | | | | | | | C and C++ don't emit an extra lexical scope for the compound statement that is the body of an Objective-C method. rdar://problem/15010825 llvm-svn: 198699
* Debug info: Ensure that the last stop point in a function is still withinAdrian Prantl2014-01-031-1/+7
| | | | | | | | | the lexical block formed by the compound statement that is the function body. rdar://problem/15010825 llvm-svn: 198461
* DebugInfo: omit debug info for friendsDavid Blaikie2013-09-131-5/+0
| | | | | | | | | GCC ToT doesn't do this & it's worth about 3.2% on Clang's DWO file size with Clang. Some or all of this may be due to things like r190715 which could have source fixes/improvements, but it's not clear that's the case and that doesn't help other source bases. llvm-svn: 190716
* CGDebugInfo: Hoist string allocation in a helper function. No functionality ↵Benjamin Kramer2013-09-091-0/+10
| | | | | | change. llvm-svn: 190314
* Fix constructor-related typos.Benjamin Kramer2013-09-091-1/+1
| | | | | | Noticed by Roman Divacky. llvm-svn: 190311
* Debug Info: pass in DIScope instead of DIDescriptor in createFieldType.Manman Ren2013-09-081-1/+1
| | | | | | Improve readability. No functionality change. llvm-svn: 190268
* Reapply r189013 (reverted in r189906) now that the underlying issue is fixed ↵David Blaikie2013-09-041-5/+5
| | | | | | | | | | | | | | and tested (in r189996) Debug info emission was tripping over an IRGen bug (fixed in r189996) that was resulting in duplicate emission of static data members of class templates in namespaces. We could add more test coverage to debug info for this issue specifically, but I think the underlying IRGen test is more targeted and sufficient for the issue. llvm-svn: 190001
* Revert "DebugInfo: Remove explicit declaration-emissiong handling now that ↵David Blaikie2013-09-041-5/+5
| | | | | | | | | | | we have a more principled approach (the 'requires complete type' callback)" This reverts commit r189013. This is causing a segfault crash in a test case I have. Reverting while I investigate the issue. llvm-svn: 189906
* Revert r189649 because it was breaking sanitizer bots.Yunzhong Gao2013-08-301-3/+3
| | | | llvm-svn: 189660
* Fixing a bug where debug info for a local variable gets emitted at file scope.Yunzhong Gao2013-08-301-3/+3
| | | | | | | The patch was discussed in Phabricator. See: http://llvm-reviews.chandlerc.com/D1281 llvm-svn: 189649
* Debug Info: update interface for CreateEnumType and getOrCreateRecordFwdDecl.Manman Ren2013-08-281-2/+2
| | | | | | | | | | Both functions will take a Type pointer instead of a Decl pointer. This helps with follow-up type uniquing patches, which need the Type pointer to call CXX mangler to generate unique identifiers. No functionality change. llvm-svn: 189519
* DebugInfo: Remove explicit declaration-emissiong handling now that we have a ↵David Blaikie2013-08-221-5/+5
| | | | | | | | more principled approach (the 'requires complete type' callback) No functionality change intended. llvm-svn: 189013
* DebugInfo: comment/inlining based on feedback from Eric & AdrianDavid Blaikie2013-08-201-3/+0
| | | | llvm-svn: 188834
* DebugInfo: Simplify/clarify propagation of typemembers between declaration ↵David Blaikie2013-08-201-2/+3
| | | | | | | | | and definition Based on code review feedback from Eric Christopher (on r188739) and Adrian Prantl (r188642). llvm-svn: 188829
* Revert "Revert "Revert "Revert "DebugInfo: Omit debug info for dynamic ↵David Blaikie2013-08-201-5/+8
| | | | | | | | | | | | | | classes in TUs that do not have the vtable for that class"""" This reverts commit r188687 (reverts r188642 (reverts 188600 (reverts 188576))). With added test coverage & fix for -gline-tables-only. Thanks Michael Gottesman for reverting this patch when it demonstrated problems & providing a reproduction/details to help me track this down. llvm-svn: 188739
* Revert "Revert "Revert "DebugInfo: Omit debug info for dynamic classes in ↵Michael Gottesman2013-08-191-8/+5
| | | | | | | | | | | | | TUs that do not have the vtable for that class""" This reverts commit r188642. This change is causing LTO builds to cause our 16 GB machines to swap and OOM all weekend. I am going to work with Dave Blaikie to resolve the issue. Sorry Dave =(. llvm-svn: 188687
* Revert "Revert "DebugInfo: Omit debug info for dynamic classes in TUs that ↵David Blaikie2013-08-181-5/+8
| | | | | | | | | | | | do not have the vtable for that class"" This reverts commit r188600. r188640/r188639 fixed the root cause of the crash-on-valid that r188600 originally introduced. This now appears to bootstrap debug clang successfully to the best of my testing. llvm-svn: 188642
* DebugInfo: Don't emit vbase 'containing types' for context chain limited typesDavid Blaikie2013-08-181-0/+1
| | | | | | | | | Possible minor reduction in debug info & avoid some cases where creating a context chain could lead to the type the context chain is being created for, being created. (this is still possible with template parameters - tests/fixes/improvements to follow) llvm-svn: 188639
* Revert "DebugInfo: Omit debug info for dynamic classes in TUs that do not ↵David Blaikie2013-08-171-8/+5
| | | | | | | | | | have the vtable for that class" This reverts commit r188576. Reverting while I investigate a selfhosting buildbot failure on Darwin. llvm-svn: 188600
* DebugInfo: Omit debug info for dynamic classes in TUs that do not have the ↵David Blaikie2013-08-161-5/+8
| | | | | | | | | vtable for that class This reduces Clang's .dwo (fission debug info) size by 23% over Clang+LLVM. llvm-svn: 188576
* DebugInfo: Contrain the record type parameter for CollectRecordFieldsDavid Blaikie2013-08-161-1/+1
| | | | | | | This is the correct type (as is demonstrated by the fact that the caller didn't need to change) & will be useful in a future patch. llvm-svn: 188575
* Revert r188498.Evgeniy Stepanov2013-08-161-1/+0
| | | | | | This change broke release+asserts build with compiler-rt. llvm-svn: 188539
* DebugInfo: CollectRecordStaticField -> CreateRecordStaticField to return its ↵David Blaikie2013-08-151-3/+2
| | | | | | result. llvm-svn: 188501
* DebugInfo: Split out the implementation of getStaticDataMemberDeclaration ↵David Blaikie2013-08-151-0/+1
| | | | | | for future use llvm-svn: 188498
* DebugInfo: Make CGDebugInfo::getStaticDataMemberDeclaration's argument type ↵David Blaikie2013-08-151-1/+1
| | | | | | | | | match the semantics Rather than having a cast immediately inside the function, push that type requirement out to the callers. llvm-svn: 188492
* DebugInfo: Unify & optimize the lazy addition of record typesDavid Blaikie2013-08-151-1/+4
| | | | | | | | | | | | | | | Rather than going through the whole getOrCreateType machinery to manifest a type, cut straight to the implementation because we know we have to do work. While the previous implementation was sufficient for the two cases (completeness and required completeness) we have already (the general machinery could inspect the type for those attributes & go down the full definition path), a pending change (to emit info for types when we emit their vtables) won't have that luxury & we'll need to force the creation rather than relying on the general purpose routine. llvm-svn: 188486
* DebugInfo: Revert change to the return type of createRecordFwdDeclDavid Blaikie2013-08-151-2/+1
| | | | | | | It still does only return DICompositeType, but I've no need to make that change right now. llvm-svn: 188482
* DebugInfo: Don't create duplicate forward declaration metadata unnecessarily.David Blaikie2013-08-151-3/+3
| | | | | | | No functionality change, at best a slight (questionable) optimization, but necessary for correctness of future work. llvm-svn: 188474
* DebugInfo: simplify some limited/declaration creation APIsDavid Blaikie2013-08-121-5/+1
| | | | llvm-svn: 188214
* typo.Adrian Prantl2013-07-251-1/+1
| | | | llvm-svn: 187089
* Debug Info: Fix an oversight of r186553. Ensure that the function prologueAdrian Prantl2013-07-241-3/+10
| | | | | | of an artificial function gets an artificial location as well. llvm-svn: 187074
* s/BuiltinLocation/ArtificialLocation/Adrian Prantl2013-07-181-6/+6
| | | | llvm-svn: 186557
* Replace llvm::DIBuilder::DisableDebugLocations() with two RAII interfacesAdrian Prantl2013-07-181-0/+36
| | | | | | | | | | | | | inspired by CodegenFunction::LexicalScope. - NoLocation temporarily turns off debug locations altogether. This is useful for emitting instructions that should be counted towards the function prologue. - BuiltinLocation temporarily switches to an artificial debug location that has a valid scope, but no line information. This is useful when emitting compiler-generated helper functions that have no source location associated with them. llvm-svn: 186552
* Reformat line.Eric Christopher2013-07-141-2/+1
| | | | llvm-svn: 186294
* Move BlockLiteralGeneric earlier in CGDebugInfo and removeEric Christopher2013-07-141-3/+1
| | | | | | | BlockLiteralGenericSet and replace with a call to isType() on the BlockLiteralGeneric. llvm-svn: 186293
* DebugInfo: Support (using GNU extensions) for template template parameters ↵David Blaikie2013-06-221-1/+1
| | | | | | and parameter packs llvm-svn: 184644
* Fix all the silly things I committed in r184509David Blaikie2013-06-211-1/+1
| | | | llvm-svn: 184512
* Alternative fix for r184473.David Blaikie2013-06-211-0/+2
| | | | | | | | | | | This just seems a bit tidier/more principled. Based on a patch provided by Adrian - with the only minor tweak that it needed to use "getTypeOrNull" rather than "getCompletedTypeOrNull" since we don't store declarations in the CompletedTypes cache. No intended functionality change. llvm-svn: 184509
* PR16214: Debug Info: -flimit-debug-info doesn't omit definitions for types ↵David Blaikie2013-06-051-5/+5
| | | | | | | | | | | | | | | | | | | | used via typedefs In an effort to make -flimit-debug-info more consistent I over-shot the mark & made types used via typedefs never produce definitions in the debug info (even if the type was used in a way that would require a definition). The fix for this is to do exactly what I was hoping to do at some point - plumb the declaration/definition choice through the various layers of "CreateType" in CGDebugInfo. In this way we can produce declarations whenever they are sufficient & definitions otherwise - including when qualifiers are used, for example (discovered in PR14467). This may not be complete (there may be other types/situations where we need to propagate the "declaration/definition" choice) but it lays the basic foundation which we can enhance in future iterations. llvm-svn: 183296
* DebugInfo: Rename CreatePointerType to getOrCreateTypeDeclarationDavid Blaikie2013-05-241-1/+1
| | | | | | | | | | | | | | | | To make this more consistent with 'getOrCreateType' & clarify the distinction between the two. The only thing I couldn't quite communicate in the name is that getOrCreateTypeDeclaration may actually produce a full definition (in -fno-limit-debug-info) but the point is to call it whenever only a declaration is needed & the implementation can choose whether to provide a declaration or definition. (also, unfortunately, getOrCreateType can produce declarations too - we should sure this up by making it not do that - any caller that can tolerate a declaration should be calling getOrCreateTypeDeclaration instead) llvm-svn: 182674
* Debug Info: Handle function/method types using the most specific typeDavid Blaikie2013-05-221-5/+5
| | | | llvm-svn: 182533
* PR14606: Debug Info for namespace aliases/DW_TAG_imported_moduleDavid Blaikie2013-05-201-0/+4
| | | | | | | | | This resolves the last of the PR14606 failures in the GDB 7.5 test suite. (but there are still unresolved issues in the imported_decl case - we need to implement optional/lazy decls for functions & variables like we already do for types) llvm-svn: 182329
* Make this const since it never changes (and should never change).Eric Christopher2013-05-201-1/+1
| | | | llvm-svn: 182309
* Revert "Revert "Debug Info: Using declarations/DW_TAG_imported_declaration ↵David Blaikie2013-05-201-0/+13
| | | | | | | | | | | | | | | | | | | | | of variables, types, and functions."" This reverts commit r181947 (git d2990ce56a16050cac0d7937ec9919ff54c6df62 ) This addresses one of the two issues identified in r181947, ensuring that types imported via using declarations only result in a declaration being emitted for the type, not a definition. The second issue (emitting using declarations that are unused) is hopefully an acceptable increase as the real fix for this would be a bit difficult (probably at best we could record which using directives were involved in lookups - but may not have been the result of the lookup). This also ensures that DW_TAG_imported_declarations (& directives) are not emitted in line-tables-only mode as well as ensuring that typedefs only require/emit declarations (rather than definitions) for referenced types. llvm-svn: 182231
OpenPOWER on IntegriCloud