This is an archive of the discontinued LLVM Phabricator instance.

[asan] Give global metadata private linkage.
ClosedPublic

Authored by eugenis on Apr 10 2017, 5:11 PM.

Details

Reviewers
kubamracek
pcc
rnk
Summary

Internal linkage preserves names like "__asan_global_foo" which may
account to 2% of unstripped binary size.

Diff Detail

Repository
rL LLVM

Event Timeline

eugenis created this revision.Apr 10 2017, 5:11 PM
pcc added inline comments.Apr 10 2017, 5:15 PM
lib/Transforms/Instrumentation/AddressSanitizer.cpp
1695

I suspect that private linkage isn't correct for darwin because the symbols need to be present in the object files for dead stripping to work, but I'll ask @kubamracek to comment on that.

rnk accepted this revision.Apr 10 2017, 6:33 PM

lgtm

This revision is now accepted and ready to land.Apr 10 2017, 6:33 PM
eugenis updated this revision to Diff 94900.Apr 11 2017, 3:17 PM

Kept the linkage internal on MachO.

pcc accepted this revision.Apr 11 2017, 3:20 PM

LGTM

eugenis closed this revision.Apr 11 2017, 3:41 PM

r299995