[PATCH] D40925: Add option -fkeep-static-consts
Elizabeth Andrews via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 10 14:00:26 PST 2018
eandrews added a comment.
Thanks for the review Reid. Sorry for the delay in my response. I was OOO.
I am not sure if a new attribute is necessary. __ attribute __(used) is already supported in Clang. While this attribute can be used to retain static constants, it would require the user to modify the source which may not always be possible/practical. Its also interesting to note that GCC actually retains unused static constants by default. fno-keep-static-consts is used to remove unused static constants in GCC.
https://reviews.llvm.org/D40925
More information about the cfe-commits
mailing list