On Fri, Oct 10, 2025 at 03:47:23PM +0100, Yury Khrustalev wrote:
> On Wed, Oct 08, 2025 at 11:25:28AM +0200, Jakub Jelinek wrote:
> > > ...
> > > Just to confirm, you don't want to add DW_AT_bit_stride to
> > > DW_TAG_array_type
> > > entry and *instead* add DW_AT_bit_size 1 in the base type? And if GDB
> > > still doesn't work, then fix it on the GDB side?
> >
> > I want both, DW_AT_bit_size 1 on the DW_AT_type referenced DIE (made up
> > anyway, it isn't reusing the normal bool DW_TAG_base_type) and
> > DW_AT_bit_stride 1 on the DW_TAG_array_type with DW_AT_GNU_vector flag.
> > And only if the vector type is the packed boolean vector, not for other
> > cases.
> >
> > Jakub
> >
>
> Question about best way to locate the referenced DIE: I could perhaps
> use modified_type_die() with element_type, but it would be call again
> shortly after when a reference is added to the DW_TAG_array_type DIE
> (from within add_type_attribute()).
Why? Doesn't get_AT_ref (die, DW_AT_type) work?
Jakub