|
Mark Wielaard |
925e93 |
commit 10922b70b825a0a9b4df9694ceb9f20e93e2c11d
|
|
Mark Wielaard |
925e93 |
Author: Mark Wielaard <mark@klomp.org>
|
|
Mark Wielaard |
925e93 |
Date: Sat Sep 18 02:19:13 2021 +0200
|
|
Mark Wielaard |
925e93 |
|
|
Mark Wielaard |
925e93 |
m_debuginfo: Handle DW_TAG_atomic_type
|
|
Mark Wielaard |
925e93 |
|
|
Mark Wielaard |
925e93 |
DW_TAG_atomic_type is a DWARF5 qualifier tag like DW_TAG_volatile_type,
|
|
Mark Wielaard |
925e93 |
DW_TAG_const_type and DW_TAG_restrict_type.
|
|
Mark Wielaard |
925e93 |
|
|
Mark Wielaard |
925e93 |
diff --git a/coregrind/m_debuginfo/readdwarf3.c b/coregrind/m_debuginfo/readdwarf3.c
|
|
Mark Wielaard |
925e93 |
index 52c27d4bb..968c37bd6 100644
|
|
Mark Wielaard |
925e93 |
--- a/coregrind/m_debuginfo/readdwarf3.c
|
|
Mark Wielaard |
925e93 |
+++ b/coregrind/m_debuginfo/readdwarf3.c
|
|
Mark Wielaard |
925e93 |
@@ -4191,14 +4191,15 @@ static void parse_type_DIE ( /*MOD*/XArray* /* of TyEnt */ tyents,
|
|
Mark Wielaard |
925e93 |
}
|
|
Mark Wielaard |
925e93 |
|
|
Mark Wielaard |
925e93 |
if (dtag == DW_TAG_volatile_type || dtag == DW_TAG_const_type
|
|
Mark Wielaard |
925e93 |
- || dtag == DW_TAG_restrict_type) {
|
|
Mark Wielaard |
925e93 |
+ || dtag == DW_TAG_restrict_type || dtag == DW_TAG_atomic_type) {
|
|
Mark Wielaard |
925e93 |
Int have_ty = 0;
|
|
Mark Wielaard |
925e93 |
VG_(memset)(&typeE, 0, sizeof(typeE));
|
|
Mark Wielaard |
925e93 |
typeE.cuOff = D3_INVALID_CUOFF;
|
|
Mark Wielaard |
925e93 |
typeE.tag = Te_TyQual;
|
|
Mark Wielaard |
925e93 |
typeE.Te.TyQual.qual
|
|
Mark Wielaard |
925e93 |
= (dtag == DW_TAG_volatile_type ? 'V'
|
|
Mark Wielaard |
925e93 |
- : (dtag == DW_TAG_const_type ? 'C' : 'R'));
|
|
Mark Wielaard |
925e93 |
+ : (dtag == DW_TAG_const_type ? 'C'
|
|
Mark Wielaard |
925e93 |
+ : (dtag == DW_TAG_restrict_type ? 'R' : 'A')));
|
|
Mark Wielaard |
925e93 |
/* target type defaults to 'void' */
|
|
Mark Wielaard |
925e93 |
typeE.Te.TyQual.typeR = D3_FAKEVOID_CUOFF;
|
|
Mark Wielaard |
925e93 |
nf_i = 0;
|
|
Mark Wielaard |
925e93 |
diff --git a/coregrind/m_debuginfo/tytypes.c b/coregrind/m_debuginfo/tytypes.c
|
|
Mark Wielaard |
925e93 |
index 75e4cf500..e356b92c9 100644
|
|
Mark Wielaard |
925e93 |
--- a/coregrind/m_debuginfo/tytypes.c
|
|
Mark Wielaard |
925e93 |
+++ b/coregrind/m_debuginfo/tytypes.c
|
|
Mark Wielaard |
925e93 |
@@ -295,6 +295,7 @@ void ML_(pp_TyEnt_C_ishly)( const XArray* /* of TyEnt */ tyents,
|
|
Mark Wielaard |
925e93 |
case 'C': VG_(printf)("const "); break;
|
|
Mark Wielaard |
925e93 |
case 'V': VG_(printf)("volatile "); break;
|
|
Mark Wielaard |
925e93 |
case 'R': VG_(printf)("restrict "); break;
|
|
Mark Wielaard |
925e93 |
+ case 'A': VG_(printf)("atomic "); break;
|
|
Mark Wielaard |
925e93 |
default: goto unhandled;
|
|
Mark Wielaard |
925e93 |
}
|
|
Mark Wielaard |
925e93 |
ML_(pp_TyEnt_C_ishly)(tyents, ent->Te.TyQual.typeR);
|