summaryrefslogtreecommitdiffstats
path: root/test/CodeGenCXX/debug-info-cxx1y.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Update Clang for D20147 ("DebugInfo: New metadata representation for global ↵Peter Collingbourne2016-09-131-3/+3
| | | | | | | | variables.") Differential Revision: http://reviews.llvm.org/D20415 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@281285 91177308-0d34-0410-b5e6-96231b3b80d8
* PR26423: Assert on valid use of using declaration of a function with an ↵David Blaikie2016-08-051-4/+22
| | | | | | | | | | | | undeduced auto return type For now just disregard the using declaration in this case. Suboptimal, but wiring up the ability to have declarations of functions that are separate from their definition (we currently only do that for member functions) and have differing return types (we don't have any support for that) is more work than seems reasonable to at least fix this crash. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@277852 91177308-0d34-0410-b5e6-96231b3b80d8
* DebugInfo: Adapt to loss of DITypeRef in LLVM r267296Duncan P. N. Exon Smith2016-04-231-3/+3
| | | | | | | | | | | | | LLVM stopped using MDString-based type references, and DIBuilder no longer fills 'retainedTypes:' with every DICompositeType that has an 'identifier:' field. There are just minor changes to keep the same behaviour in CFE. Leaving 'retainedTypes:' unfilled has a dramatic impact on the output order of the IR though. There are a huge number of testcase changes, which were unfortunately not really scriptable. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@267297 91177308-0d34-0410-b5e6-96231b3b80d8
* Stop messing with the 'g' group of options in CompilerInvocation.Douglas Katzman2015-10-081-1/+1
| | | | | | | | | | | | | | | | With this change, most 'g' options are rejected by CompilerInvocation. They remain only as Driver options. The new way to request debug info from cc1 is with "-debug-info-kind={line-tables-only|limited|standalone}" and "-dwarf-version={2|3|4}". In the absence of a command-line option to specify Dwarf version, the Toolchain decides it, rather than placing Toolchain-specific logic in CompilerInvocation. Also fix a bug in the Windows compatibility argument parsing in which the "rightmost argument wins" principle failed. Differential Revision: http://reviews.llvm.org/D13221 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@249655 91177308-0d34-0410-b5e6-96231b3b80d8
* DebugInfo: Metadata constructs now start with DI*Duncan P. N. Exon Smith2015-04-291-5/+5
| | | | | | | | | | LLVM r236120 renamed debug info IR constructs to use a `DI` prefix, now that the `DIDescriptor` hierarchy has been gone for about a week. This commit was generated using the rename-md-di-nodes.sh upgrade script attached to PR23080, followed by running clang-format-diff.py on the `lib/` portion of the patch. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@236121 91177308-0d34-0410-b5e6-96231b3b80d8
* DebugInfo: Move new hierarchy into place (clang)Duncan P. N. Exon Smith2015-03-031-5/+12
| | | | | | | Update testcases for LLVM change in r231082 to use the new debug info hierarchy. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@231083 91177308-0d34-0410-b5e6-96231b3b80d8
* IR: Make metadata typeless in assembly, clang sideDuncan P. N. Exon Smith2014-12-151-6/+6
| | | | | | Match LLVM changes from r224257. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@224259 91177308-0d34-0410-b5e6-96231b3b80d8
* clang/test/CodeGenCXX/debug-info-cxx1y.cpp: Add %itanium_abi_triple for ↵NAKAMURA Takumi2014-11-111-1/+1
| | | | | | incompatible MS targets. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@221741 91177308-0d34-0410-b5e6-96231b3b80d8
* PR16091 continued: Debug Info for member functions with undeduced return types.David Blaikie2014-11-111-2/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | So DWARF5 specs out auto deduced return types as DW_TAG_unspecified_type with DW_AT_name "auto", and GCC implements this somewhat, but it presents a few problems to do this with Clang. GCC's implementation only applies to member functions where the auto return type isn't deduced immediately (ie: member functions of templates or member functions defined out of line). In the common case of an inline deduced return type function, GCC emits the DW_AT_type as the deduced return type. Currently GDB doesn't seem to behave too well with this debug info - it treats the return type as 'void', even though the definition of the function has the correctly deduced return type (I guess it sees the return type the declaration has, doesn't understand it, and assumes void). This means the function's ABI might be broken (non-trivial return types, etc), etc. Clang, on the other hand doesn't track this particular case of a deducable return type that is deduced immediately versus one that is deduced 'later'. So if we implement the DWARF5 representation, all deducible return type functions would get adverse GDB behavior (including deduced return type lambda functions, inline deduced return type functions, etc). Also, we can't just do this for auto types that are not deduced - because Clang marks even the declaration's return type as deduced (& provides the underlying type) once a definition is seen that allows the deduction. So we have to ignore even deduced types - but we can't do that for auto variables (because this representation only applies to function declarations - variables and function definitions need the real type so the function can be called, etc) so we'd need to add an extra flag to the type unwrapping/creation code to indicate when we want to see through deduced types and when we don't. It's also not as simple as just checking at the top level when building a function type (for one thing, we reuse the function type building for building function pointer types which might also have 'auto' in them - but be the type of a variable instead) because the auto might be arbitrarily deeply nested ("auto &", "auto (*)()", etc...) So, with all that said, let's do the simple thing that works in existing debuggers for now and treat these functions the same way we do function templates and implicit special members: omit them from the member list, since they can't be correctly called anyway (without knowing the return type the ABI isn't know and a function call could put the arguments in the wrong place) so they're not much use to the user. At some point in the future, when GDB understands the DWARF5 representation better it might be worth plumbing through the extra type builder handling to avoid looking through AutoType for some callers, etc... git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@221704 91177308-0d34-0410-b5e6-96231b3b80d8
* Add 'not' to commands that are expected to fail.Rafael Espindola2013-07-041-1/+1
| | | | | | | This is at least good documentation, but also opens the possibility of using pipefail. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@185652 91177308-0d34-0410-b5e6-96231b3b80d8
* PR16091: Error when attempting to emit debug info for undeduced auto return ↵David Blaikie2013-05-241-0/+7
types Perhaps we should just suppress this, rather than erroring, but since we have the infrastructure for it I figured I'd use it - if this is determined to be not the right thing we should probably remove that infrastructure entirely. I guess it's lying around from the early days of implementing debug info support. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@182673 91177308-0d34-0410-b5e6-96231b3b80d8