mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-16 10:20:30 +00:00
DWARF emitted by clang 3.7 encodes array sizes using the DW_AT_count
attribute rather than DW_AT_upper_bound. Teach ctfconvert about this so that array type sizes are encoded correctly. PR: 203772 MFC after: 1 week
This commit is contained in:
parent
872fb8b006
commit
a4dc509f72
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=289866
@ -683,6 +683,10 @@ tdesc_array_create(dwarf_t *dw, Dwarf_Die dim, tdesc_t *arrtdp,
|
||||
ar->ad_nelems = uval + 1;
|
||||
else if (die_signed(dw, dim, DW_AT_upper_bound, &sval, 0))
|
||||
ar->ad_nelems = sval + 1;
|
||||
else if (die_unsigned(dw, dim, DW_AT_count, &uval, 0))
|
||||
ar->ad_nelems = uval;
|
||||
else if (die_signed(dw, dim, DW_AT_count, &sval, 0))
|
||||
ar->ad_nelems = sval;
|
||||
else
|
||||
ar->ad_nelems = 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user