diff options
author | Chris Lattner <sabre@nondot.org> | 2004-10-16 18:04:13 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2004-10-16 18:04:13 +0000 |
commit | 35eca58d7a211523d0dbdcfeec3eaa3aab71fa75 (patch) | |
tree | f76c8480f996302d572150ce4b8b9922d0f40bc5 /docs | |
parent | a1dad814dff441a4a82d4524e7a9313b09d1df5a (diff) | |
download | llvm-35eca58d7a211523d0dbdcfeec3eaa3aab71fa75.tar.gz llvm-35eca58d7a211523d0dbdcfeec3eaa3aab71fa75.tar.bz2 llvm-35eca58d7a211523d0dbdcfeec3eaa3aab71fa75.tar.xz |
Document unreachable instruction
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17033 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'docs')
-rw-r--r-- | docs/LangRef.html | 67 |
1 files changed, 53 insertions, 14 deletions
diff --git a/docs/LangRef.html b/docs/LangRef.html index 1a2093634f..18912ac07e 100644 --- a/docs/LangRef.html +++ b/docs/LangRef.html @@ -51,6 +51,7 @@ <li><a href="#i_switch">'<tt>switch</tt>' Instruction</a></li> <li><a href="#i_invoke">'<tt>invoke</tt>' Instruction</a></li> <li><a href="#i_unwind">'<tt>unwind</tt>' Instruction</a></li> + <li><a href="#i_unreachable">'<tt>unreachable</tt>' Instruction</a></li> </ol> </li> <li><a href="#binaryops">Binary Operations</a> @@ -753,8 +754,9 @@ the '<a href="#i_invoke"><tt>invoke</tt></a>' instruction).</p> <p>There are five different terminator instructions: the '<a href="#i_ret"><tt>ret</tt></a>' instruction, the '<a href="#i_br"><tt>br</tt></a>' instruction, the '<a href="#i_switch"><tt>switch</tt></a>' instruction, -the '<a href="#i_invoke"><tt>invoke</tt></a>' instruction, and the '<a - href="#i_unwind"><tt>unwind</tt></a>' instruction.</p> +the '<a href="#i_invoke"><tt>invoke</tt></a>' instruction, the '<a + href="#i_unwind"><tt>unwind</tt></a>' instruction, and the '<a + href="#i_unreachable"><tt>unreachable</tt></a>' instruction.</p> </div> <!-- _______________________________________________________________________ --> <div class="doc_subsubsection"> <a name="i_ret">'<tt>ret</tt>' @@ -920,26 +922,63 @@ support them.</p> <pre> %retval = invoke int %Test(int 15)<br> to label %Continue<br> except label %TestCleanup <i>; {int}:retval set</i> </pre> </div> + + <!-- _______________________________________________________________________ --> + <div class="doc_subsubsection"> <a name="i_unwind">'<tt>unwind</tt>' Instruction</a> </div> + <div class="doc_text"> + <h5>Syntax:</h5> -<pre> unwind<br></pre> +<pre> + unwind +</pre> + <h5>Overview:</h5> -<p>The '<tt>unwind</tt>' instruction unwinds the stack, continuing -control flow at the first callee in the dynamic call stack which used -an <a href="#i_invoke"><tt>invoke</tt></a> instruction to perform the -call. This is primarily used to implement exception handling.</p> + +<p>The '<tt>unwind</tt>' instruction unwinds the stack, continuing control flow +at the first callee in the dynamic call stack which used an <a +href="#i_invoke"><tt>invoke</tt></a> instruction to perform the call. This is +primarily used to implement exception handling.</p> + <h5>Semantics:</h5> -<p>The '<tt>unwind</tt>' intrinsic causes execution of the current -function to immediately halt. The dynamic call stack is then searched -for the first <a href="#i_invoke"><tt>invoke</tt></a> instruction on -the call stack. Once found, execution continues at the "exceptional" -destination block specified by the <tt>invoke</tt> instruction. If -there is no <tt>invoke</tt> instruction in the dynamic call chain, -undefined behavior results.</p> + +<p>The '<tt>unwind</tt>' intrinsic causes execution of the current function to +immediately halt. The dynamic call stack is then searched for the first <a +href="#i_invoke"><tt>invoke</tt></a> instruction on the call stack. Once found, +execution continues at the "exceptional" destination block specified by the +<tt>invoke</tt> instruction. If there is no <tt>invoke</tt> instruction in the +dynamic call chain, undefined behavior results.</p> </div> + +<!-- _______________________________________________________________________ --> + +<div class="doc_subsubsection"> <a name="i_unreachable">'<tt>unreachable</tt>' +Instruction</a> </div> + +<div class="doc_text"> + +<h5>Syntax:</h5> +<pre> + unreachable +</pre> + +<h5>Overview:</h5> + +<p>The '<tt>unreachable</tt>' instruction has no defined semantics. This +instruction is used to inform the optimizer that a particular portion of the +code is not reachable. This can be used to indicate that the code after a +no-return function cannot be reached, and other facts.</p> + +<h5>Semantics:</h5> + +<p>The '<tt>unreachable</tt>' instruction has no defined semantics.</p> +</div> + + + <!-- ======================================================================= --> <div class="doc_subsection"> <a name="binaryops">Binary Operations</a> </div> <div class="doc_text"> |