diff options
author | Mark Harmstone <mark@harmstone.com> | 2024-11-01 00:38:44 +0000 |
---|---|---|
committer | Mark Harmstone <mark@harmstone.com> | 2024-11-05 00:47:35 +0000 |
commit | b0f4f556ea9f07d0b6fb6407ab25a193d27c806e (patch) | |
tree | a38ca846223932eab0eaa2018a6f1944ad9e6f87 /gcc/dwarf2codeview.h | |
parent | 7ac24078e06d95ecd234b5bfa07ff8dd47650791 (diff) | |
download | gcc-b0f4f556ea9f07d0b6fb6407ab25a193d27c806e.zip gcc-b0f4f556ea9f07d0b6fb6407ab25a193d27c806e.tar.gz gcc-b0f4f556ea9f07d0b6fb6407ab25a193d27c806e.tar.bz2 |
Write LF_POINTER CodeView types for pointers to member functions or data
Translate DW_TAG_ptr_to_member_type DIEs into special extended
LF_POINTER CodeView types.
gcc/
* dwarf2codeview.cc (struct codeview_custom_type): Add new fields to
lf_pointer struct in union.
(write_lf_pointer): Write containing_class and ptr_to_mem_type if
applicable.
(get_type_num_subroutine_type): Write correct containing_class_type if
this is a pointer to a member function.
(get_type_num_ptr_to_member_type): New function.
(get_type_num): Call get_type_num_ptr_to_member_type.
* dwarf2codeview.h (CV_PTR_MODE_MASK, CV_PTR_MODE_PMEM): Define.
(CV_PTR_MODE_PMFUNC, CV_PMTYPE_D_Single, CV_PMTYPE_F_Single): Likewise.
Diffstat (limited to 'gcc/dwarf2codeview.h')
-rw-r--r-- | gcc/dwarf2codeview.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gcc/dwarf2codeview.h b/gcc/dwarf2codeview.h index c631349..c895ef3 100644 --- a/gcc/dwarf2codeview.h +++ b/gcc/dwarf2codeview.h @@ -55,9 +55,18 @@ along with GCC; see the file COPYING3. If not see /* LF_POINTER attributes. */ #define CV_PTR_NEAR32 0x0a #define CV_PTR_64 0x0c + +/* enum CV_ptrmode_e in cvinfo.h, shifted by 5 for the lfPointerAttr bitfield */ +#define CV_PTR_MODE_MASK 0xe0 #define CV_PTR_MODE_LVREF 0x20 +#define CV_PTR_MODE_PMEM 0x40 +#define CV_PTR_MODE_PMFUNC 0x60 #define CV_PTR_MODE_RVREF 0x80 +/* enum CV_pmtype_e in in cvinfo.h */ +#define CV_PMTYPE_D_Single 0x01 +#define CV_PMTYPE_F_Single 0x05 + /* LF_MODIFIER values. */ #define MOD_const 0x1 #define MOD_volatile 0x2 |