aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authormark <mark@138bc75d-0d04-0410-961f-82ee72b054a4>2014-11-26 10:10:27 +0000
committermark <mark@138bc75d-0d04-0410-961f-82ee72b054a4>2014-11-26 10:10:27 +0000
commitaa643a01560ad7b603ec0c5f6e0f715271ef9822 (patch)
tree0da2d62552111f8cf417b00f86b89e8a9353c9cb /include
parent6968257f9e3c408dcb7f91ece080f8a654ba5275 (diff)
DWARF add DW_AT_noreturn on noreturn function subprogram.
This implements the DWARFv5 noreturn proposal: http://dwarfstd.org/ShowIssue.php?issue=140331.1 TREE_THIS_VOLATILE on a FUNCTION_DECL node means the function does not return normally. This catches the traditional noreturn GNU attribute, the C11 _Noreturn keyword and the C++11 [[noreturn]] attribute. This relies on the DW_AT_noreturn constant defined in the DWARFv5 DRAFT: http://www.dwarfstd.org/doc/dwarf5.20141029.pdf gcc/ChangeLog * dwarf2out.c (gen_subprogram_die): Add DW_AT_noreturn when the function decl has TREE_THIS_VOLATILE. gcc/testsuite/ChangeLog * g++.dg/debug/dwarf2/noreturn-function.C: New test. * gcc.dg/debug/dwarf2/noreturn-function-attribute.c: Likewise. * gcc.dg/debug/dwarf2/noreturn-function-keyword.c: Likewise. include/ChangeLog * dwarf2.def (DW_AT_noreturn): New DWARF5 attribute. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@218075 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'include')
-rw-r--r--include/ChangeLog4
-rw-r--r--include/dwarf2.def2
2 files changed, 6 insertions, 0 deletions
diff --git a/include/ChangeLog b/include/ChangeLog
index ea7fba60ae1..e73a9a89df6 100644
--- a/include/ChangeLog
+++ b/include/ChangeLog
@@ -1,3 +1,7 @@
+2014-11-25 Mark Wielaard <mjw@redhat.com>
+
+ * dwarf2.def (DW_AT_noreturn): New DWARF5 attribute.
+
2014-11-14 Shinichiro Hamaji <shinichiro.hamaji@gmail.com>
* dwarf2.def (DW_AT_APPLE_optimized, DW_AT_APPLE_flags)
diff --git a/include/dwarf2.def b/include/dwarf2.def
index 8ca143c5212..8533a3edbd5 100644
--- a/include/dwarf2.def
+++ b/include/dwarf2.def
@@ -308,6 +308,8 @@ DW_AT (DW_AT_data_bit_offset, 0x6b)
DW_AT (DW_AT_const_expr, 0x6c)
DW_AT (DW_AT_enum_class, 0x6d)
DW_AT (DW_AT_linkage_name, 0x6e)
+/* DWARF 5. */
+DW_AT (DW_AT_noreturn, 0x87)
DW_AT_DUP (DW_AT_lo_user, 0x2000) /* Implementation-defined range start. */
DW_AT_DUP (DW_AT_hi_user, 0x3fff) /* Implementation-defined range end. */