[PATCH] D36712: Emit section information for extern variables
Elizabeth Andrews via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Aug 14 13:58:58 PDT 2017
eandrews created this revision.
Update IR generated to retain section information for external declarations. This is related to https://reviews.llvm.org/D36487
@@ -622,6 +622,12 @@
Additionally, the global can placed in a comdat if the target has the necessary
+External declarations may have an explicit section specified. When generating
+LLVM IR, external declarations are ignored and the variables are emitted on
+their first use. While sections are not generated in the object file
+corresponding to the LLVM module, section information specified in the
+declaration is retained in LLVM IR to enable OpenCL processes.
By default, global initializers are optimized by assuming that global
variables defined within the module are not modified from their
initial values before the start of the global initializer. This is
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 820 bytes
Desc: not available
More information about the cfe-commits