diff options
author | Chris Lattner <sabre@nondot.org> | 2009-04-13 05:44:34 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-04-13 05:44:34 +0000 |
commit | 266c7bbbbcc4b326dea82e577de1a415d6acc23e (patch) | |
tree | e880304f13d90f5926ead058f546b05e325dd5a2 /docs | |
parent | 2c71b8f64f571b34e8df2a83120a2e889627b8d4 (diff) | |
download | external_llvm-266c7bbbbcc4b326dea82e577de1a415d6acc23e.zip external_llvm-266c7bbbbcc4b326dea82e577de1a415d6acc23e.tar.gz external_llvm-266c7bbbbcc4b326dea82e577de1a415d6acc23e.tar.bz2 |
Add a new "available_externally" linkage type. This is intended
to support C99 inline, GNU extern inline, etc. Related bugzilla's
include PR3517, PR3100, & PR2933. Nothing uses this yet, but it
appears to work.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@68940 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'docs')
-rw-r--r-- | docs/LangRef.html | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/docs/LangRef.html b/docs/LangRef.html index 457a56a..8ec1123 100644 --- a/docs/LangRef.html +++ b/docs/LangRef.html @@ -509,6 +509,17 @@ All Global Variables and Functions have one of the following types of linkage: '<tt>static</tt>' keyword in C. </dd> + <dt><tt><b><a name="available_externally">available_externally</a></b></tt>: + </dt> + + <dd>Globals with "<tt>available_externally</tt>" linkage are never emitted + into the object file corresponding to the LLVM module. They exist to + allow inlining and other optimizations to take place given knowledge of the + definition of the global, which is known to be somewhere outside the module. + Globals with <tt>available_externally</tt> linkage are allowed to be discarded + at will, and are otherwise the same as <tt>linkonce_odr</tt>. This linkage + type is only allowed on definitions, not declarations.</dd> + <dt><tt><b><a name="linkage_linkonce">linkonce</a></b></tt>: </dt> <dd>Globals with "<tt>linkonce</tt>" linkage are merged with other globals of @@ -554,10 +565,10 @@ All Global Variables and Functions have one of the following types of linkage: <dt><tt><b><a name="linkage_linkonce">linkonce_odr</a></b></tt>: </dt> <dt><tt><b><a name="linkage_weak">weak_odr</a></b></tt>: </dt> - <dd>Some languages allow inequivalent globals to be merged, such as two + <dd>Some languages allow differing globals to be merged, such as two functions with different semantics. Other languages, such as <tt>C++</tt>, ensure that only equivalent globals are ever merged (the "one definition - rule" - <tt>odr</tt>). Such languages can use the <tt>linkonce_odr</tt> + rule" - "ODR"). Such languages can use the <tt>linkonce_odr</tt> and <tt>weak_odr</tt> linkage types to indicate that the global will only be merged with equivalent globals. These linkage types are otherwise the same as their non-<tt>odr</tt> versions. |