Page MenuHomePhabricator

[Clang] Add addrsig attribute to mark global functions/variables as address significant.

Authored by zequanwu on Mar 9 2021, 2:44 PM.



Functions or variables with this attribute will not have local_unnamed_addr/unnamed_addr in IR. So, they will show up in address-significant table.

Diff Detail

Event Timeline

zequanwu created this revision.Mar 9 2021, 2:44 PM
zequanwu requested review of this revision.Mar 9 2021, 2:44 PM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptMar 9 2021, 2:44 PM
zequanwu updated this revision to Diff 330099.Mar 11 2021, 4:19 PM

Split clang change and IR change.

I'm not opposed to the attribute per se, but I'd like to understand the motivation behind it a bit more. It seems like it solves a special edge case for a specific linker and I'm wondering if that's sufficient motivation for the community to support the attribute or not.


You should also have a test that the attribute does not accept any arguments.

zequanwu abandoned this revision.Mar 22 2021, 2:39 PM

This overlaps with the functionality of attribute used.