libdwarf: Add definitions for Apple's DWARF extension attributes.

Reviewed by:	emaste
MFC after:	1 week
This commit is contained in:
Mark Johnston 2016-09-20 00:22:35 +00:00
parent bff11ce594
commit feba6b4163
2 changed files with 41 additions and 0 deletions

View File

@ -234,6 +234,21 @@
#define DW_AT_GNU_all_call_sites 0x2117
#define DW_AT_GNU_all_source_call_sites 0x2118
/* Apple extensions. */
#define DW_AT_APPLE_optimized 0x3fe1
#define DW_AT_APPLE_flags 0x3fe2
#define DW_AT_APPLE_isa 0x3fe3
#define DW_AT_APPLE_block 0x3fe4
#define DW_AT_APPLE_major_runtime_vers 0x3fe5
#define DW_AT_APPLE_runtime_class 0x3fe6
#define DW_AT_APPLE_omit_frame_ptr 0x3fe7
#define DW_AT_APPLE_property_name 0x3fe8
#define DW_AT_APPLE_property_getter 0x3fe9
#define DW_AT_APPLE_property_setter 0x3fea
#define DW_AT_APPLE_property_attribute 0x3feb
#define DW_AT_APPLE_objc_complete_type 0x3fec
#define DW_AT_APPLE_property 0x3fed
#define DW_FORM_addr 0x01
#define DW_FORM_block2 0x03
#define DW_FORM_block4 0x04

View File

@ -298,6 +298,32 @@ dwarf_get_AT_name(unsigned attr, const char **s)
*s = "DW_AT_GNU_all_call_sites"; break;
case DW_AT_GNU_all_source_call_sites:
*s = "DW_AT_GNU_all_source_call_sites"; break;
case DW_AT_APPLE_optimized:
*s = "DW_AT_APPLE_optimized"; break;
case DW_AT_APPLE_flags:
*s = "DW_AT_APPLE_flags"; break;
case DW_AT_APPLE_isa:
*s = "DW_AT_APPLE_isa"; break;
case DW_AT_APPLE_block:
*s = "DW_AT_APPLE_block"; break;
case DW_AT_APPLE_major_runtime_vers:
*s = "DW_AT_APPLE_major_runtime_vers"; break;
case DW_AT_APPLE_runtime_class:
*s = "DW_AT_APPLE_runtime_class"; break;
case DW_AT_APPLE_omit_frame_ptr:
*s = "DW_AT_APPLE_omit_frame_ptr"; break;
case DW_AT_APPLE_property_name:
*s = "DW_AT_APPLE_property_name"; break;
case DW_AT_APPLE_property_getter:
*s = "DW_AT_APPLE_property_getter"; break;
case DW_AT_APPLE_property_setter:
*s = "DW_AT_APPLE_property_setter"; break;
case DW_AT_APPLE_property_attribute:
*s = "DW_AT_APPLE_property_attribute"; break;
case DW_AT_APPLE_objc_complete_type:
*s = "DW_AT_APPLE_objc_complete_type"; break;
case DW_AT_APPLE_property:
*s = "DW_AT_APPLE_property"; break;
default:
return (DW_DLV_NO_ENTRY);
}