[Dwarf-discuss] Additional values for DW_AT_accessibility

Ben Woodard woodard@redhat.com
Tue Apr 28 17:17:29 GMT 2026


On 4/25/26 12:28 AM, Martin via Dwarf-discuss wrote:
> Hi,
>
> Thanks for looking into it.
>
> On 25/04/2026 03:17, Ben Woodard wrote:
>> I guess these have ABI implications as well and so they probably 
>> would need to be tracked so they would need to be available for tools 
>> like libabigail.
>>
>> While a tool like gdb probably wouldn’t care about the difference 
>> between “Private” and “Strict Private”, libabigail would need know if 
>> a member or a method changed from one to another. This would likely 
>> be more of an API level ABI change rather than a structural or 
>> calling convention change.
>
> I am no expert on the ABI question. My involvement comes from 
> maintaining a debugger.
>
> gdb does show the information on request (and so does "FpDebug", the 
> debugger for which I would like to use this):
>
> ptype TFoo
> type = struct TFoo : public TObject {
>   protected:
>     LongInt ABC;
>   private:
>     LongInt Bar;
> }
>
> That is what brought my attention to the absence of them.
>
>
>> Do you think we really need “Published”? I can’t see any reason why 
>> that one is needed in DWARF.
>
> As I said, not an expert on API, but from a quick Google, this is 
> purely cosmetic. (as the documentation says, for actual access its the 
> same as public).
>
The ABI thing would come up if you wanted an ABI checker like libabigail 
to be able to detect when a particular member changes from: Private to 
Strict Private. That changes the API of the interface and consequently 
changes the ABI of the resulting object. It doesn't at all change the 
calling convention.

Anyway, I'll file the DWARF Issue for you. Then the Chair will assign it 
an issue. It doesn't sound very controversial.

-ben

> Tools relying on the generated RTTI don't (to my knowledge) rely on 
> DWARF. So it would be only for a debugger to show the info as above.
>



More information about the Dwarf-discuss mailing list