Implement protected visibility. This partly implements PR1363. Linker
should be taught to deal with protected symbols.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36565 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/docs/BytecodeFormat.html b/docs/BytecodeFormat.html
index f479ca5..1dc9c74 100644
--- a/docs/BytecodeFormat.html
+++ b/docs/BytecodeFormat.html
@@ -1044,7 +1044,7 @@
     </tr>
     <tr>
       <td><a href="#bit">bit(10-12)</a></td>
-      <td class="td_left">Visibility style: 0=Default, 1=Hidden.</td>
+      <td class="td_left">Visibility style: 0=Default, 1=Hidden, 2=Protected.</td>
     </tr>
     <tr>
       <td><a href="#bit">bit(13-31)</a></td>
@@ -1506,7 +1506,7 @@
     </tr>
     <tr>
       <td><a href="#bit">bit(16-18)</a></td>
-      <td class="td_left">Visibility style: 0=Default, 1=Hidden.</td>
+      <td class="td_left">Visibility style: 0=Default, 1=Hidden, 2=Protected.</td>
     </tr>
     <tr>
       <td><a href="#bit">bit(19-31)</a></td>
diff --git a/docs/LangRef.html b/docs/LangRef.html
index 67a2fc8..58e0e3c 100644
--- a/docs/LangRef.html
+++ b/docs/LangRef.html
@@ -591,6 +591,13 @@
     directly.
   </dd>
 
+  <dt><b>"<tt>protected</tt>" - Protected style</b>:</dt>
+
+  <dd>On ELF, protected visibility indicates that the symbol will be placed in
+  the dynamic symbol table, but that references within the defining module will
+  bind to the local symbol. That is, the symbol cannot be overridden by another
+  module.
+  </dd>
 </dl>
 
 </div>