rnk accepted this revision.
rnk added a comment.
This revision is now accepted and ready to land.

lgtm with a minor doc tweak

My reading of the discussion is that this is ready, but please wait for others 
if you are aware of any outstanding concerns.



================
Comment at: clang/include/clang/Basic/AttrDocs.td:98
+
+This attribute only has an effect on ELF targets; other targets prevent the
+removal of definitions by the linker when using the ``used`` attribute alone.
----------------
The attribute does have an effect on non-ELF targets: a retained global will be 
added to llvm.used, if it ends up being emitted. Maybe you can say that the 
attribute is only necessary on ELF targets, and that there is no harm in using 
`retain` in addition to `used` on non-ELF targets. Using the attributes 
together should result in consistent behavior across platforms.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97447/new/

https://reviews.llvm.org/D97447

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to