Sophie

Sophie

distrib > Mageia > 5 > i586 > media > core-release > by-pkgid > 6e204a966e8c42d976f99a1700ce5f20 > files > 2933

ghc-7.4.2-4.mga5.i586.rpm

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Llvm</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Llvm.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">ghc-7.4.2: The GHC API</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>None</td></tr></table><p class="caption">Llvm</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Modules, Functions and Blocks
</a></li><li><a href="#g:2">Fence synchronization
</a></li><li><a href="#g:3">Call Handling
</a></li><li><a href="#g:4">Operations and Comparisons
</a></li><li><a href="#g:5">Variables and Type System
</a><ul><li><a href="#g:6">Some basic types
</a></li><li><a href="#g:7">Operations on the type system.
</a></li></ul></li><li><a href="#g:8">Pretty Printing
</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module supplies bindings to generate Llvm IR from Haskell
 (<a href="http://www.llvm.org/docs/LangRef.html">http://www.llvm.org/docs/LangRef.html</a>).
</p><p>Note: this module is developed in a demand driven way. It is no complete
 LLVM binding library in Haskell, but enough to generate code for GHC.
</p><p>This code is derived from code taken from the Essential Haskell Compiler
 (EHC) project (<a href="http://www.cs.uu.nl/wiki/Ehc/WebHome">http://www.cs.uu.nl/wiki/Ehc/WebHome</a>).
</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmModule">LlvmModule</a>  = <a href="#v:LlvmModule">LlvmModule</a> {<ul class="subs"><li><a href="#v:modComments">modComments</a> :: [<a href="Llvm.html#t:LMString">LMString</a>]</li><li><a href="#v:modAliases">modAliases</a> :: [<a href="Llvm.html#t:LlvmAlias">LlvmAlias</a>]</li><li><a href="#v:modGlobals">modGlobals</a> :: [<a href="Llvm.html#t:LMGlobal">LMGlobal</a>]</li><li><a href="#v:modFwdDecls">modFwdDecls</a> :: <a href="Llvm.html#t:LlvmFunctionDecls">LlvmFunctionDecls</a></li><li><a href="#v:modFuncs">modFuncs</a> :: <a href="Llvm.html#t:LlvmFunctions">LlvmFunctions</a></li></ul>}</li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmFunction">LlvmFunction</a>  = <a href="#v:LlvmFunction">LlvmFunction</a> {<ul class="subs"><li><a href="#v:funcDecl">funcDecl</a> :: <a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a></li><li><a href="#v:funcArgs">funcArgs</a> :: [<a href="Llvm.html#t:LMString">LMString</a>]</li><li><a href="#v:funcAttrs">funcAttrs</a> :: [<a href="Llvm.html#t:LlvmFuncAttr">LlvmFuncAttr</a>]</li><li><a href="#v:funcSect">funcSect</a> :: <a href="Llvm.html#t:LMSection">LMSection</a></li><li><a href="#v:funcBody">funcBody</a> :: <a href="Llvm.html#t:LlvmBlocks">LlvmBlocks</a></li></ul>}</li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmFunctionDecl">LlvmFunctionDecl</a>  = <a href="#v:LlvmFunctionDecl">LlvmFunctionDecl</a> {<ul class="subs"><li><a href="#v:decName">decName</a> :: <a href="Llvm.html#t:LMString">LMString</a></li><li><a href="#v:funcLinkage">funcLinkage</a> :: <a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a></li><li><a href="#v:funcCc">funcCc</a> :: <a href="Llvm.html#t:LlvmCallConvention">LlvmCallConvention</a></li><li><a href="#v:decReturnType">decReturnType</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li><a href="#v:decVarargs">decVarargs</a> :: <a href="Llvm.html#t:LlvmParameterListType">LlvmParameterListType</a></li><li><a href="#v:decParams">decParams</a> :: [<a href="Llvm.html#t:LlvmParameter">LlvmParameter</a>]</li><li><a href="#v:funcAlign">funcAlign</a> :: <a href="Llvm.html#t:LMAlign">LMAlign</a></li></ul>}</li><li class="src short"><span class="keyword">type</span> <a href="#t:LlvmFunctions">LlvmFunctions</a> = [<a href="Llvm.html#t:LlvmFunction">LlvmFunction</a>]</li><li class="src short"><span class="keyword">type</span> <a href="#t:LlvmFunctionDecls">LlvmFunctionDecls</a> = [<a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a>]</li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmStatement">LlvmStatement</a> <ul class="subs"><li>= <a href="#v:Assignment">Assignment</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmExpression">LlvmExpression</a>  </li><li>| <a href="#v:Fence">Fence</a> <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="Llvm.html#t:LlvmSyncOrdering">LlvmSyncOrdering</a>  </li><li>| <a href="#v:Branch">Branch</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>  </li><li>| <a href="#v:BranchIf">BranchIf</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>  </li><li>| <a href="#v:Comment">Comment</a> [<a href="Llvm.html#t:LMString">LMString</a>]  </li><li>| <a href="#v:MkLabel">MkLabel</a> <a href="Llvm.html#t:LlvmBlockId">LlvmBlockId</a>  </li><li>| <a href="#v:Store">Store</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>  </li><li>| <a href="#v:Switch">Switch</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> [(<a href="Llvm.html#t:LlvmVar">LlvmVar</a>, <a href="Llvm.html#t:LlvmVar">LlvmVar</a>)]  </li><li>| <a href="#v:Return">Return</a> (<a href="../base-4.5.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>)  </li><li>| <a href="#v:Unreachable">Unreachable</a>  </li><li>| <a href="#v:Expr">Expr</a> <a href="Llvm.html#t:LlvmExpression">LlvmExpression</a>  </li><li>| <a href="#v:Nop">Nop</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmExpression">LlvmExpression</a> <ul class="subs"><li>= <a href="#v:Alloca">Alloca</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a>  </li><li>| <a href="#v:LlvmOp">LlvmOp</a> <a href="Llvm.html#t:LlvmMachOp">LlvmMachOp</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>  </li><li>| <a href="#v:Compare">Compare</a> <a href="Llvm.html#t:LlvmCmpOp">LlvmCmpOp</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>  </li><li>| <a href="#v:Malloc">Malloc</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a>  </li><li>| <a href="#v:Load">Load</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>  </li><li>| <a href="#v:GetElemPtr">GetElemPtr</a> <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> [<a href="Llvm.html#t:LlvmVar">LlvmVar</a>]  </li><li>| <a href="#v:Cast">Cast</a> <a href="Llvm.html#t:LlvmCastOp">LlvmCastOp</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:Call">Call</a> <a href="Llvm.html#t:LlvmCallType">LlvmCallType</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> [<a href="Llvm.html#t:LlvmVar">LlvmVar</a>] [<a href="Llvm.html#t:LlvmFuncAttr">LlvmFuncAttr</a>]  </li><li>| <a href="#v:Phi">Phi</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> [(<a href="Llvm.html#t:LlvmVar">LlvmVar</a>, <a href="Llvm.html#t:LlvmVar">LlvmVar</a>)]  </li><li>| <a href="#v:Asm">Asm</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> [<a href="Llvm.html#t:LlvmVar">LlvmVar</a>] <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a>  </li></ul></li><li class="src short"><span class="keyword">type</span> <a href="#t:LlvmBlocks">LlvmBlocks</a> = [<a href="Llvm.html#t:LlvmBlock">LlvmBlock</a>]</li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmBlock">LlvmBlock</a>  = <a href="#v:LlvmBlock">LlvmBlock</a> {<ul class="subs"><li><a href="#v:blockLabel">blockLabel</a> :: <a href="Llvm.html#t:LlvmBlockId">LlvmBlockId</a></li><li><a href="#v:blockStmts">blockStmts</a> :: [<a href="Llvm.html#t:LlvmStatement">LlvmStatement</a>]</li></ul>}</li><li class="src short"><span class="keyword">type</span> <a href="#t:LlvmBlockId">LlvmBlockId</a> = <a href="Unique.html#t:Unique">Unique</a></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmParamAttr">LlvmParamAttr</a> <ul class="subs"><li>= <a href="#v:ZeroExt">ZeroExt</a>  </li><li>| <a href="#v:SignExt">SignExt</a>  </li><li>| <a href="#v:InReg">InReg</a>  </li><li>| <a href="#v:ByVal">ByVal</a>  </li><li>| <a href="#v:SRet">SRet</a>  </li><li>| <a href="#v:NoAlias">NoAlias</a>  </li><li>| <a href="#v:NoCapture">NoCapture</a>  </li><li>| <a href="#v:Nest">Nest</a>  </li></ul></li><li class="src short"><span class="keyword">type</span> <a href="#t:LlvmParameter">LlvmParameter</a> = (<a href="Llvm.html#t:LlvmType">LlvmType</a>, [<a href="Llvm.html#t:LlvmParamAttr">LlvmParamAttr</a>])</li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmSyncOrdering">LlvmSyncOrdering</a> <ul class="subs"><li>= <a href="#v:SyncUnord">SyncUnord</a>  </li><li>| <a href="#v:SyncMonotonic">SyncMonotonic</a>  </li><li>| <a href="#v:SyncAcquire">SyncAcquire</a>  </li><li>| <a href="#v:SyncRelease">SyncRelease</a>  </li><li>| <a href="#v:SyncAcqRel">SyncAcqRel</a>  </li><li>| <a href="#v:SyncSeqCst">SyncSeqCst</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmCallConvention">LlvmCallConvention</a> <ul class="subs"><li>= <a href="#v:CC_Ccc">CC_Ccc</a>  </li><li>| <a href="#v:CC_Fastcc">CC_Fastcc</a>  </li><li>| <a href="#v:CC_Coldcc">CC_Coldcc</a>  </li><li>| <a href="#v:CC_Ncc">CC_Ncc</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a>  </li><li>| <a href="#v:CC_X86_Stdcc">CC_X86_Stdcc</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmCallType">LlvmCallType</a> <ul class="subs"><li>= <a href="#v:StdCall">StdCall</a>  </li><li>| <a href="#v:TailCall">TailCall</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmParameterListType">LlvmParameterListType</a> <ul class="subs"><li>= <a href="#v:FixedArgs">FixedArgs</a>  </li><li>| <a href="#v:VarArgs">VarArgs</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmLinkageType">LlvmLinkageType</a> <ul class="subs"><li>= <a href="#v:Internal">Internal</a>  </li><li>| <a href="#v:LinkOnce">LinkOnce</a>  </li><li>| <a href="#v:Weak">Weak</a>  </li><li>| <a href="#v:Appending">Appending</a>  </li><li>| <a href="#v:ExternWeak">ExternWeak</a>  </li><li>| <a href="#v:ExternallyVisible">ExternallyVisible</a>  </li><li>| <a href="#v:External">External</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmFuncAttr">LlvmFuncAttr</a> <ul class="subs"><li>= <a href="#v:AlwaysInline">AlwaysInline</a>  </li><li>| <a href="#v:InlineHint">InlineHint</a>  </li><li>| <a href="#v:NoInline">NoInline</a>  </li><li>| <a href="#v:OptSize">OptSize</a>  </li><li>| <a href="#v:NoReturn">NoReturn</a>  </li><li>| <a href="#v:NoUnwind">NoUnwind</a>  </li><li>| <a href="#v:ReadNone">ReadNone</a>  </li><li>| <a href="#v:ReadOnly">ReadOnly</a>  </li><li>| <a href="#v:Ssp">Ssp</a>  </li><li>| <a href="#v:SspReq">SspReq</a>  </li><li>| <a href="#v:NoRedZone">NoRedZone</a>  </li><li>| <a href="#v:NoImplicitFloat">NoImplicitFloat</a>  </li><li>| <a href="#v:Naked">Naked</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmCmpOp">LlvmCmpOp</a> <ul class="subs"><li>= <a href="#v:LM_CMP_Eq">LM_CMP_Eq</a>  </li><li>| <a href="#v:LM_CMP_Ne">LM_CMP_Ne</a>  </li><li>| <a href="#v:LM_CMP_Ugt">LM_CMP_Ugt</a>  </li><li>| <a href="#v:LM_CMP_Uge">LM_CMP_Uge</a>  </li><li>| <a href="#v:LM_CMP_Ult">LM_CMP_Ult</a>  </li><li>| <a href="#v:LM_CMP_Ule">LM_CMP_Ule</a>  </li><li>| <a href="#v:LM_CMP_Sgt">LM_CMP_Sgt</a>  </li><li>| <a href="#v:LM_CMP_Sge">LM_CMP_Sge</a>  </li><li>| <a href="#v:LM_CMP_Slt">LM_CMP_Slt</a>  </li><li>| <a href="#v:LM_CMP_Sle">LM_CMP_Sle</a>  </li><li>| <a href="#v:LM_CMP_Feq">LM_CMP_Feq</a>  </li><li>| <a href="#v:LM_CMP_Fne">LM_CMP_Fne</a>  </li><li>| <a href="#v:LM_CMP_Fgt">LM_CMP_Fgt</a>  </li><li>| <a href="#v:LM_CMP_Fge">LM_CMP_Fge</a>  </li><li>| <a href="#v:LM_CMP_Flt">LM_CMP_Flt</a>  </li><li>| <a href="#v:LM_CMP_Fle">LM_CMP_Fle</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmMachOp">LlvmMachOp</a> <ul class="subs"><li>= <a href="#v:LM_MO_Add">LM_MO_Add</a>  </li><li>| <a href="#v:LM_MO_Sub">LM_MO_Sub</a>  </li><li>| <a href="#v:LM_MO_Mul">LM_MO_Mul</a>  </li><li>| <a href="#v:LM_MO_UDiv">LM_MO_UDiv</a>  </li><li>| <a href="#v:LM_MO_SDiv">LM_MO_SDiv</a>  </li><li>| <a href="#v:LM_MO_URem">LM_MO_URem</a>  </li><li>| <a href="#v:LM_MO_SRem">LM_MO_SRem</a>  </li><li>| <a href="#v:LM_MO_FAdd">LM_MO_FAdd</a>  </li><li>| <a href="#v:LM_MO_FSub">LM_MO_FSub</a>  </li><li>| <a href="#v:LM_MO_FMul">LM_MO_FMul</a>  </li><li>| <a href="#v:LM_MO_FDiv">LM_MO_FDiv</a>  </li><li>| <a href="#v:LM_MO_FRem">LM_MO_FRem</a>  </li><li>| <a href="#v:LM_MO_Shl">LM_MO_Shl</a>  </li><li>| <a href="#v:LM_MO_LShr">LM_MO_LShr</a>  </li><li>| <a href="#v:LM_MO_AShr">LM_MO_AShr</a>  </li><li>| <a href="#v:LM_MO_And">LM_MO_And</a>  </li><li>| <a href="#v:LM_MO_Or">LM_MO_Or</a>  </li><li>| <a href="#v:LM_MO_Xor">LM_MO_Xor</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmCastOp">LlvmCastOp</a> <ul class="subs"><li>= <a href="#v:LM_Trunc">LM_Trunc</a>  </li><li>| <a href="#v:LM_Zext">LM_Zext</a>  </li><li>| <a href="#v:LM_Sext">LM_Sext</a>  </li><li>| <a href="#v:LM_Fptrunc">LM_Fptrunc</a>  </li><li>| <a href="#v:LM_Fpext">LM_Fpext</a>  </li><li>| <a href="#v:LM_Fptoui">LM_Fptoui</a>  </li><li>| <a href="#v:LM_Fptosi">LM_Fptosi</a>  </li><li>| <a href="#v:LM_Uitofp">LM_Uitofp</a>  </li><li>| <a href="#v:LM_Sitofp">LM_Sitofp</a>  </li><li>| <a href="#v:LM_Ptrtoint">LM_Ptrtoint</a>  </li><li>| <a href="#v:LM_Inttoptr">LM_Inttoptr</a>  </li><li>| <a href="#v:LM_Bitcast">LM_Bitcast</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmVar">LlvmVar</a> <ul class="subs"><li>= <a href="#v:LMGlobalVar">LMGlobalVar</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> <a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a> <a href="Llvm.html#t:LMSection">LMSection</a> <a href="Llvm.html#t:LMAlign">LMAlign</a> <a href="Llvm-Types.html#t:LMConst">LMConst</a>  </li><li>| <a href="#v:LMLocalVar">LMLocalVar</a> <a href="Unique.html#t:Unique">Unique</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMNLocalVar">LMNLocalVar</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMLitVar">LMLitVar</a> <a href="Llvm.html#t:LlvmLit">LlvmLit</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmStatic">LlvmStatic</a> <ul class="subs"><li>= <a href="#v:LMComment">LMComment</a> <a href="Llvm.html#t:LMString">LMString</a>  </li><li>| <a href="#v:LMStaticLit">LMStaticLit</a> <a href="Llvm.html#t:LlvmLit">LlvmLit</a>  </li><li>| <a href="#v:LMUninitType">LMUninitType</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMStaticStr">LMStaticStr</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMStaticArray">LMStaticArray</a> [<a href="Llvm.html#t:LlvmStatic">LlvmStatic</a>] <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMStaticStruc">LMStaticStruc</a> [<a href="Llvm.html#t:LlvmStatic">LlvmStatic</a>] <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMStaticPointer">LMStaticPointer</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>  </li><li>| <a href="#v:LMBitc">LMBitc</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMPtoI">LMPtoI</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMAdd">LMAdd</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a>  </li><li>| <a href="#v:LMSub">LMSub</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmLit">LlvmLit</a> <ul class="subs"><li>= <a href="#v:LMIntLit">LMIntLit</a> <a href="../base-4.5.1.0/Prelude.html#t:Integer">Integer</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMFloatLit">LMFloatLit</a> <a href="../base-4.5.1.0/Prelude.html#t:Double">Double</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMNullLit">LMNullLit</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMUndefLit">LMUndefLit</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li></ul></li><li class="src short"><span class="keyword">data</span>  <a href="#t:LlvmType">LlvmType</a> <ul class="subs"><li>= <a href="#v:LMInt">LMInt</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a>  </li><li>| <a href="#v:LMFloat">LMFloat</a>  </li><li>| <a href="#v:LMDouble">LMDouble</a>  </li><li>| <a href="#v:LMFloat80">LMFloat80</a>  </li><li>| <a href="#v:LMFloat128">LMFloat128</a>  </li><li>| <a href="#v:LMPointer">LMPointer</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMArray">LMArray</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a> <a href="Llvm.html#t:LlvmType">LlvmType</a>  </li><li>| <a href="#v:LMLabel">LMLabel</a>  </li><li>| <a href="#v:LMVoid">LMVoid</a>  </li><li>| <a href="#v:LMStruct">LMStruct</a> [<a href="Llvm.html#t:LlvmType">LlvmType</a>]  </li><li>| <a href="#v:LMAlias">LMAlias</a> <a href="Llvm.html#t:LlvmAlias">LlvmAlias</a>  </li><li>| <a href="#v:LMFunction">LMFunction</a> <a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a>  </li></ul></li><li class="src short"><span class="keyword">type</span> <a href="#t:LlvmAlias">LlvmAlias</a> = (<a href="Llvm.html#t:LMString">LMString</a>, <a href="Llvm.html#t:LlvmType">LlvmType</a>)</li><li class="src short"><span class="keyword">type</span> <a href="#t:LMGlobal">LMGlobal</a> = (<a href="Llvm.html#t:LlvmVar">LlvmVar</a>, <a href="../base-4.5.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a>)</li><li class="src short"><span class="keyword">type</span> <a href="#t:LMString">LMString</a> = <a href="FastString.html#t:FastString">FastString</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:LMSection">LMSection</a> = <a href="../base-4.5.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="Llvm.html#t:LMString">LMString</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:LMAlign">LMAlign</a> = <a href="../base-4.5.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a></li><li class="src short"><a href="#v:i64">i64</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:i32">i32</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:i16">i16</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:i8">i8</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:i1">i1</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:i8Ptr">i8Ptr</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:llvmWord">llvmWord</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:llvmWordPtr">llvmWordPtr</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:isGlobal">isGlobal</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:getLitType">getLitType</a> :: <a href="Llvm.html#t:LlvmLit">LlvmLit</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:getLit">getLit</a> :: <a href="Llvm.html#t:LlvmLit">LlvmLit</a> -&gt; <a href="../base-4.5.1.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:getName">getName</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="../base-4.5.1.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:getPlainName">getPlainName</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="../base-4.5.1.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:getVarType">getVarType</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:getLink">getLink</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a></li><li class="src short"><a href="#v:getStatType">getStatType</a> :: <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:getGlobalVar">getGlobalVar</a> :: <a href="Llvm.html#t:LMGlobal">LMGlobal</a> -&gt; <a href="Llvm.html#t:LlvmVar">LlvmVar</a></li><li class="src short"><a href="#v:getGlobalType">getGlobalType</a> :: <a href="Llvm.html#t:LMGlobal">LMGlobal</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:pVarLift">pVarLift</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="Llvm.html#t:LlvmVar">LlvmVar</a></li><li class="src short"><a href="#v:pVarLower">pVarLower</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="Llvm.html#t:LlvmVar">LlvmVar</a></li><li class="src short"><a href="#v:pLift">pLift</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:pLower">pLower</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></li><li class="src short"><a href="#v:isInt">isInt</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:isFloat">isFloat</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:isPointer">isPointer</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:llvmWidthInBits">llvmWidthInBits</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a></li><li class="src short"><a href="#v:ppLlvmModule">ppLlvmModule</a> :: <a href="Llvm.html#t:LlvmModule">LlvmModule</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmComments">ppLlvmComments</a> :: [<a href="Llvm.html#t:LMString">LMString</a>] -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmComment">ppLlvmComment</a> :: <a href="Llvm.html#t:LMString">LMString</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmGlobals">ppLlvmGlobals</a> :: [<a href="Llvm.html#t:LMGlobal">LMGlobal</a>] -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmGlobal">ppLlvmGlobal</a> :: <a href="Llvm.html#t:LMGlobal">LMGlobal</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmFunctionDecls">ppLlvmFunctionDecls</a> :: <a href="Llvm.html#t:LlvmFunctionDecls">LlvmFunctionDecls</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmFunctionDecl">ppLlvmFunctionDecl</a> :: <a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmFunctions">ppLlvmFunctions</a> :: <a href="Llvm.html#t:LlvmFunctions">LlvmFunctions</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmFunction">ppLlvmFunction</a> :: <a href="Llvm.html#t:LlvmFunction">LlvmFunction</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmAlias">ppLlvmAlias</a> :: <a href="Llvm.html#t:LlvmAlias">LlvmAlias</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:ppLlvmAliases">ppLlvmAliases</a> :: [<a href="Llvm.html#t:LlvmAlias">LlvmAlias</a>] -&gt; <a href="Pretty.html#t:Doc">Doc</a></li><li class="src short"><a href="#v:llvmSDoc">llvmSDoc</a> :: <a href="Outputable.html#t:SDoc">SDoc</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></li></ul></div><div id="interface"><h1 id="g:1">Modules, Functions and Blocks
</h1><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmModule" class="def">LlvmModule</a>  </p><div class="doc"><p>An LLVM Module. This is a top level container in LLVM.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LlvmModule" class="def">LlvmModule</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:modComments" class="def">modComments</a> :: [<a href="Llvm.html#t:LMString">LMString</a>]</dt><dd class="doc"><p>Comments to include at the start of the module.
</p></dd><dt class="src"><a name="v:modAliases" class="def">modAliases</a> :: [<a href="Llvm.html#t:LlvmAlias">LlvmAlias</a>]</dt><dd class="doc"><p>LLVM Alias type definitions.
</p></dd><dt class="src"><a name="v:modGlobals" class="def">modGlobals</a> :: [<a href="Llvm.html#t:LMGlobal">LMGlobal</a>]</dt><dd class="doc"><p>Global variables to include in the module.
</p></dd><dt class="src"><a name="v:modFwdDecls" class="def">modFwdDecls</a> :: <a href="Llvm.html#t:LlvmFunctionDecls">LlvmFunctionDecls</a></dt><dd class="doc"><p>LLVM Functions used in this module but defined in other modules.
</p></dd><dt class="src"><a name="v:modFuncs" class="def">modFuncs</a> :: <a href="Llvm.html#t:LlvmFunctions">LlvmFunctions</a></dt><dd class="doc"><p>LLVM Functions defined in this module.
</p></dd></dl><div class="clear"></div></div></td></tr></table></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmFunction" class="def">LlvmFunction</a>  </p><div class="doc"><p>An LLVM Function
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LlvmFunction" class="def">LlvmFunction</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:funcDecl" class="def">funcDecl</a> :: <a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a></dt><dd class="doc"><p>The signature of this declared function.
</p></dd><dt class="src"><a name="v:funcArgs" class="def">funcArgs</a> :: [<a href="Llvm.html#t:LMString">LMString</a>]</dt><dd class="doc"><p>The functions arguments
</p></dd><dt class="src"><a name="v:funcAttrs" class="def">funcAttrs</a> :: [<a href="Llvm.html#t:LlvmFuncAttr">LlvmFuncAttr</a>]</dt><dd class="doc"><p>The function attributes.
</p></dd><dt class="src"><a name="v:funcSect" class="def">funcSect</a> :: <a href="Llvm.html#t:LMSection">LMSection</a></dt><dd class="doc"><p>The section to put the function into,
</p></dd><dt class="src"><a name="v:funcBody" class="def">funcBody</a> :: <a href="Llvm.html#t:LlvmBlocks">LlvmBlocks</a></dt><dd class="doc"><p>The body of the functions.
</p></dd></dl><div class="clear"></div></div></td></tr></table></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmFunctionDecl" class="def">LlvmFunctionDecl</a>  </p><div class="doc"><p>An LLVM Function
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LlvmFunctionDecl" class="def">LlvmFunctionDecl</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:decName" class="def">decName</a> :: <a href="Llvm.html#t:LMString">LMString</a></dt><dd class="doc"><p>Unique identifier of the function
</p></dd><dt class="src"><a name="v:funcLinkage" class="def">funcLinkage</a> :: <a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a></dt><dd class="doc"><p>LinkageType of the function
</p></dd><dt class="src"><a name="v:funcCc" class="def">funcCc</a> :: <a href="Llvm.html#t:LlvmCallConvention">LlvmCallConvention</a></dt><dd class="doc"><p>The calling convention of the function
</p></dd><dt class="src"><a name="v:decReturnType" class="def">decReturnType</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></dt><dd class="doc"><p>Type of the returned value
</p></dd><dt class="src"><a name="v:decVarargs" class="def">decVarargs</a> :: <a href="Llvm.html#t:LlvmParameterListType">LlvmParameterListType</a></dt><dd class="doc"><p>Indicates if this function uses varargs
</p></dd><dt class="src"><a name="v:decParams" class="def">decParams</a> :: [<a href="Llvm.html#t:LlvmParameter">LlvmParameter</a>]</dt><dd class="doc"><p>Parameter types and attributes
</p></dd><dt class="src"><a name="v:funcAlign" class="def">funcAlign</a> :: <a href="Llvm.html#t:LMAlign">LMAlign</a></dt><dd class="doc"><p>Function align value, must be power of 2
</p></dd></dl><div class="clear"></div></div></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmFunctionDecl" class="caption collapser" onclick="toggleSection('i:LlvmFunctionDecl')">Instances</p><div id="section.i:LlvmFunctionDecl" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LlvmFunctions" class="def">LlvmFunctions</a> = [<a href="Llvm.html#t:LlvmFunction">LlvmFunction</a>]</p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LlvmFunctionDecls" class="def">LlvmFunctionDecls</a> = [<a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a>]</p></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmStatement" class="def">LlvmStatement</a>  </p><div class="doc"><p>Llvm Statements
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:Assignment" class="def">Assignment</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmExpression">LlvmExpression</a></td><td class="doc"><p>Assign an expression to an variable:
      * dest:   Variable to assign to
      * source: Source expression
</p></td></tr><tr><td class="src"><a name="v:Fence" class="def">Fence</a> <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="Llvm.html#t:LlvmSyncOrdering">LlvmSyncOrdering</a></td><td class="doc"><p>Memory fence operation
</p></td></tr><tr><td class="src"><a name="v:Branch" class="def">Branch</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc"><p>Always branch to the target label
</p></td></tr><tr><td class="src"><a name="v:BranchIf" class="def">BranchIf</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc"><p>Branch to label targetTrue if cond is true otherwise to label targetFalse
      * cond:        condition that will be tested, must be of type i1
      * targetTrue:  label to branch to if cond is true
      * targetFalse: label to branch to if cond is false
</p></td></tr><tr><td class="src"><a name="v:Comment" class="def">Comment</a> [<a href="Llvm.html#t:LMString">LMString</a>]</td><td class="doc"><p>Comment
    Plain comment.
</p></td></tr><tr><td class="src"><a name="v:MkLabel" class="def">MkLabel</a> <a href="Llvm.html#t:LlvmBlockId">LlvmBlockId</a></td><td class="doc"><p>Set a label on this position.
      * name: Identifier of this label, unique for this module
</p></td></tr><tr><td class="src"><a name="v:Store" class="def">Store</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc"><p>Store variable value in pointer ptr. If value is of type t then ptr must
    be of type t*.
      * value: Variable/Constant to store.
      * ptr:   Location to store the value in
</p></td></tr><tr><td class="src"><a name="v:Switch" class="def">Switch</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> [(<a href="Llvm.html#t:LlvmVar">LlvmVar</a>, <a href="Llvm.html#t:LlvmVar">LlvmVar</a>)]</td><td class="doc"><p>Mutliway branch
      * scrutinee: Variable or constant which must be of integer type that is
                   determines which arm is chosen.
      * def:       The default label if there is no match in target.
      * target:    A list of (value,label) where the value is an integer
                   constant and label the corresponding label to jump to if the
                   scrutinee matches the value.
</p></td></tr><tr><td class="src"><a name="v:Return" class="def">Return</a> (<a href="../base-4.5.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a>)</td><td class="doc"><p>Return a result.
      * result: The variable or constant to return
</p></td></tr><tr><td class="src"><a name="v:Unreachable" class="def">Unreachable</a></td><td class="doc"><p>An instruction for the optimizer that the code following is not reachable
</p></td></tr><tr><td class="src"><a name="v:Expr" class="def">Expr</a> <a href="Llvm.html#t:LlvmExpression">LlvmExpression</a></td><td class="doc"><p>Raise an expression to a statement (if don't want result or want to use
    Llvm unnamed values.
</p></td></tr><tr><td class="src"><a name="v:Nop" class="def">Nop</a></td><td class="doc"><p>A nop LLVM statement. Useful as its often more efficient to use this
    then to wrap LLvmStatement in a Just or [].
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmStatement" class="caption collapser" onclick="toggleSection('i:LlvmStatement')">Instances</p><div id="section.i:LlvmStatement" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmStatement">LlvmStatement</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmStatement">LlvmStatement</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmExpression" class="def">LlvmExpression</a>  </p><div class="doc"><p>Llvm Expressions
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:Alloca" class="def">Alloca</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a></td><td class="doc"><p>Allocate amount * sizeof(tp) bytes on the stack
      * tp:     LlvmType to reserve room for
      * amount: The nr of tp's which must be allocated
</p></td></tr><tr><td class="src"><a name="v:LlvmOp" class="def">LlvmOp</a> <a href="Llvm.html#t:LlvmMachOp">LlvmMachOp</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc"><p>Perform the machine operator op on the operands left and right
      * op:    operator
      * left:  left operand
      * right: right operand
</p></td></tr><tr><td class="src"><a name="v:Compare" class="def">Compare</a> <a href="Llvm.html#t:LlvmCmpOp">LlvmCmpOp</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc"><p>Perform a compare operation on the operands left and right
      * op:    operator
      * left:  left operand
      * right: right operand
</p></td></tr><tr><td class="src"><a name="v:Malloc" class="def">Malloc</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a></td><td class="doc"><p>Allocate amount * sizeof(tp) bytes on the heap
      * tp:     LlvmType to reserve room for
      * amount: The nr of tp's which must be allocated
</p></td></tr><tr><td class="src"><a name="v:Load" class="def">Load</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc"><p>Load the value at location ptr
</p></td></tr><tr><td class="src"><a name="v:GetElemPtr" class="def">GetElemPtr</a> <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> [<a href="Llvm.html#t:LlvmVar">LlvmVar</a>]</td><td class="doc"><p>Navigate in an structure, selecting elements
      * inbound: Is the pointer inbounds? (computed pointer doesn't overflow)
      * ptr:     Location of the structure
      * indexes: A list of indexes to select the correct value.
</p></td></tr><tr><td class="src"><a name="v:Cast" class="def">Cast</a> <a href="Llvm.html#t:LlvmCastOp">LlvmCastOp</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Cast the variable from to the to type. This is an abstraction of three
     cast operators in Llvm, inttoptr, prttoint and bitcast.
       * cast: Cast type
       * from: Variable to cast
       * to:   type to cast to
</p></td></tr><tr><td class="src"><a name="v:Call" class="def">Call</a> <a href="Llvm.html#t:LlvmCallType">LlvmCallType</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a> [<a href="Llvm.html#t:LlvmVar">LlvmVar</a>] [<a href="Llvm.html#t:LlvmFuncAttr">LlvmFuncAttr</a>]</td><td class="doc"><p>Call a function. The result is the value of the expression.
      * tailJumps: CallType to signal if the function should be tail called
      * fnptrval:  An LLVM value containing a pointer to a function to be
                   invoked. Can be indirect. Should be LMFunction type.
      * args:      Concrete arguments for the parameters
      * attrs:     A list of function attributes for the call. Only NoReturn,
                   NoUnwind, ReadOnly and ReadNone are valid here.
</p></td></tr><tr><td class="src"><a name="v:Phi" class="def">Phi</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> [(<a href="Llvm.html#t:LlvmVar">LlvmVar</a>, <a href="Llvm.html#t:LlvmVar">LlvmVar</a>)]</td><td class="doc"><p>Merge variables from different basic blocks which are predecessors of this
    basic block in a new variable of type tp.
      * tp:         type of the merged variable, must match the types of the
                    predecessor variables.
      * precessors: A list of variables and the basic block that they originate
                    from.
</p></td></tr><tr><td class="src"><a name="v:Asm" class="def">Asm</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> [<a href="Llvm.html#t:LlvmVar">LlvmVar</a>] <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a> <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Inline assembly expression. Syntax is very similar to the style used by GCC.
      * assembly:   Actual inline assembly code.
      * contraints: Operand constraints.
      * return ty:  Return type of function.
      * vars:       Any variables involved in the assembly code.
      * sideeffect: Does the expression have side effects not visible from the
                    constraints list.
      * alignstack: Should the stack be conservatively aligned before this
                    expression is executed.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmExpression" class="caption collapser" onclick="toggleSection('i:LlvmExpression')">Instances</p><div id="section.i:LlvmExpression" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmExpression">LlvmExpression</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmExpression">LlvmExpression</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LlvmBlocks" class="def">LlvmBlocks</a> = [<a href="Llvm.html#t:LlvmBlock">LlvmBlock</a>]</p></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmBlock" class="def">LlvmBlock</a>  </p><div class="doc"><p>A block of LLVM code.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LlvmBlock" class="def">LlvmBlock</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:blockLabel" class="def">blockLabel</a> :: <a href="Llvm.html#t:LlvmBlockId">LlvmBlockId</a></dt><dd class="doc"><p>The code label for this block
</p></dd><dt class="src"><a name="v:blockStmts" class="def">blockStmts</a> :: [<a href="Llvm.html#t:LlvmStatement">LlvmStatement</a>]</dt><dd class="doc"><p>A list of LlvmStatement's representing the code for this block.
 This list must end with a control flow statement.
</p></dd></dl><div class="clear"></div></div></td></tr></table></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LlvmBlockId" class="def">LlvmBlockId</a> = <a href="Unique.html#t:Unique">Unique</a></p><div class="doc"><p>Block labels
</p></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmParamAttr" class="def">LlvmParamAttr</a>  </p><div class="doc"><p>LLVM Parameter Attributes.
</p><p>Parameter attributes are used to communicate additional information about
 the result or parameters of a function
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ZeroExt" class="def">ZeroExt</a></td><td class="doc"><p>This indicates to the code generator that the parameter or return value
 should be zero-extended to a 32-bit value by the caller (for a parameter)
 or the callee (for a return value).
</p></td></tr><tr><td class="src"><a name="v:SignExt" class="def">SignExt</a></td><td class="doc"><p>This indicates to the code generator that the parameter or return value
 should be sign-extended to a 32-bit value by the caller (for a parameter)
 or the callee (for a return value).
</p></td></tr><tr><td class="src"><a name="v:InReg" class="def">InReg</a></td><td class="doc"><p>This indicates that this parameter or return value should be treated in
 a special target-dependent fashion during while emitting code for a
 function call or return (usually, by putting it in a register as opposed
 to memory).
</p></td></tr><tr><td class="src"><a name="v:ByVal" class="def">ByVal</a></td><td class="doc"><p>This indicates that the pointer parameter should really be passed by
 value to the function.
</p></td></tr><tr><td class="src"><a name="v:SRet" class="def">SRet</a></td><td class="doc"><p>This indicates that the pointer parameter specifies the address of a
 structure that is the return value of the function in the source program.
</p></td></tr><tr><td class="src"><a name="v:NoAlias" class="def">NoAlias</a></td><td class="doc"><p>This indicates that the pointer does not alias any global or any other
 parameter.
</p></td></tr><tr><td class="src"><a name="v:NoCapture" class="def">NoCapture</a></td><td class="doc"><p>This indicates that the callee does not make any copies of the pointer
 that outlive the callee itself
</p></td></tr><tr><td class="src"><a name="v:Nest" class="def">Nest</a></td><td class="doc"><p>This indicates that the pointer parameter can be excised using the
 trampoline intrinsics.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmParamAttr" class="caption collapser" onclick="toggleSection('i:LlvmParamAttr')">Instances</p><div id="section.i:LlvmParamAttr" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmParamAttr">LlvmParamAttr</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmParamAttr">LlvmParamAttr</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LlvmParameter" class="def">LlvmParameter</a> = (<a href="Llvm.html#t:LlvmType">LlvmType</a>, [<a href="Llvm.html#t:LlvmParamAttr">LlvmParamAttr</a>])</p></div><h1 id="g:2">Fence synchronization
</h1><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmSyncOrdering" class="def">LlvmSyncOrdering</a>  </p><div class="doc"><p>LLVM ordering types for synchronization purposes. (Introduced in LLVM
 3.0). Please see the LLVM documentation for a better description.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:SyncUnord" class="def">SyncUnord</a></td><td class="doc"><p>Some partial order of operations exists.
</p></td></tr><tr><td class="src"><a name="v:SyncMonotonic" class="def">SyncMonotonic</a></td><td class="doc"><p>A single total order for operations at a single address exists.
</p></td></tr><tr><td class="src"><a name="v:SyncAcquire" class="def">SyncAcquire</a></td><td class="doc"><p>Acquire synchronization operation.
</p></td></tr><tr><td class="src"><a name="v:SyncRelease" class="def">SyncRelease</a></td><td class="doc"><p>Release synchronization operation.
</p></td></tr><tr><td class="src"><a name="v:SyncAcqRel" class="def">SyncAcqRel</a></td><td class="doc"><p>Acquire + Release synchronization operation.
</p></td></tr><tr><td class="src"><a name="v:SyncSeqCst" class="def">SyncSeqCst</a></td><td class="doc"><p>Full sequential Consistency operation.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmSyncOrdering" class="caption collapser" onclick="toggleSection('i:LlvmSyncOrdering')">Instances</p><div id="section.i:LlvmSyncOrdering" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmSyncOrdering">LlvmSyncOrdering</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmSyncOrdering">LlvmSyncOrdering</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:3">Call Handling
</h1><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmCallConvention" class="def">LlvmCallConvention</a>  </p><div class="doc"><p>Different calling conventions a function can use.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:CC_Ccc" class="def">CC_Ccc</a></td><td class="doc"><p>The C calling convention.
 This calling convention (the default if no other calling convention is
 specified) matches the target C calling conventions. This calling
 convention supports varargs function calls and tolerates some mismatch in
 the declared prototype and implemented declaration of the function (as
 does normal C).
</p></td></tr><tr><td class="src"><a name="v:CC_Fastcc" class="def">CC_Fastcc</a></td><td class="doc"><p>This calling convention attempts to make calls as fast as possible
 (e.g. by passing things in registers). This calling convention allows
 the target to use whatever tricks it wants to produce fast code for the
 target, without having to conform to an externally specified ABI
 (Application Binary Interface). Implementations of this convention should
 allow arbitrary tail call optimization to be supported. This calling
 convention does not support varargs and requires the prototype of al
 callees to exactly match the prototype of the function definition.
</p></td></tr><tr><td class="src"><a name="v:CC_Coldcc" class="def">CC_Coldcc</a></td><td class="doc"><p>This calling convention attempts to make code in the caller as efficient
 as possible under the assumption that the call is not commonly executed.
 As such, these calls often preserve all registers so that the call does
 not break any live ranges in the caller side. This calling convention
 does not support varargs and requires the prototype of all callees to
 exactly match the prototype of the function definition.
</p></td></tr><tr><td class="src"><a name="v:CC_Ncc" class="def">CC_Ncc</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a></td><td class="doc"><p>Any calling convention may be specified by number, allowing
 target-specific calling conventions to be used. Target specific calling
 conventions start at 64.
</p></td></tr><tr><td class="src"><a name="v:CC_X86_Stdcc" class="def">CC_X86_Stdcc</a></td><td class="doc"><p>X86 Specific <code><a href="Llvm.html#v:StdCall">StdCall</a></code> convention. LLVM includes a specific alias for it
 rather than just using CC_Ncc.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmCallConvention" class="caption collapser" onclick="toggleSection('i:LlvmCallConvention')">Instances</p><div id="section.i:LlvmCallConvention" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmCallConvention">LlvmCallConvention</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmCallConvention">LlvmCallConvention</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmCallType" class="def">LlvmCallType</a>  </p><div class="doc"><p>Different types to call a function.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:StdCall" class="def">StdCall</a></td><td class="doc"><p>Normal call, allocate a new stack frame.
</p></td></tr><tr><td class="src"><a name="v:TailCall" class="def">TailCall</a></td><td class="doc"><p>Tail call, perform the call in the current stack frame.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmCallType" class="caption collapser" onclick="toggleSection('i:LlvmCallType')">Instances</p><div id="section.i:LlvmCallType" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmCallType">LlvmCallType</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmCallType">LlvmCallType</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmParameterListType" class="def">LlvmParameterListType</a>  </p><div class="doc"><p>Functions can have a fixed amount of parameters, or a variable amount.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:FixedArgs" class="def">FixedArgs</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a name="v:VarArgs" class="def">VarArgs</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:LlvmParameterListType" class="caption collapser" onclick="toggleSection('i:LlvmParameterListType')">Instances</p><div id="section.i:LlvmParameterListType" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmParameterListType">LlvmParameterListType</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmParameterListType">LlvmParameterListType</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmLinkageType" class="def">LlvmLinkageType</a>  </p><div class="doc"><p>Linkage type of a symbol.
</p><p>The description of the constructors is copied from the Llvm Assembly Language
 Reference Manual <a href="http://www.llvm.org/docs/LangRef.html#linkage">http://www.llvm.org/docs/LangRef.html#linkage</a>, because
 they correspond to the Llvm linkage types.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:Internal" class="def">Internal</a></td><td class="doc"><p>Global values with internal linkage are only directly accessible by
 objects in the current module. In particular, linking code into a module
 with an internal global value may cause the internal to be renamed as
 necessary to avoid collisions. Because the symbol is internal to the
 module, all references can be updated. This corresponds to the notion
 of the <code>static</code> keyword in C.
</p></td></tr><tr><td class="src"><a name="v:LinkOnce" class="def">LinkOnce</a></td><td class="doc"><p>Globals with <code>linkonce</code> linkage are merged with other globals of the
 same name when linkage occurs. This is typically used to implement
 inline functions, templates, or other code which must be generated
 in each translation unit that uses it. Unreferenced linkonce globals are
 allowed to be discarded.
</p></td></tr><tr><td class="src"><a name="v:Weak" class="def">Weak</a></td><td class="doc"><p><code>weak</code> linkage is exactly the same as linkonce linkage, except that
 unreferenced weak globals may not be discarded. This is used for globals
 that may be emitted in multiple translation units, but that are not
 guaranteed to be emitted into every translation unit that uses them. One
 example of this are common globals in C, such as <code>int X;</code> at global
 scope.
</p></td></tr><tr><td class="src"><a name="v:Appending" class="def">Appending</a></td><td class="doc"><p><code>appending</code> linkage may only be applied to global variables of pointer
 to array type. When two global variables with appending linkage are
 linked together, the two global arrays are appended together. This is
 the Llvm, typesafe, equivalent of having the system linker append
 together <code>sections</code> with identical names when .o files are linked.
</p></td></tr><tr><td class="src"><a name="v:ExternWeak" class="def">ExternWeak</a></td><td class="doc"><p>The semantics of this linkage follow the ELF model: the symbol is weak
 until linked, if not linked, the symbol becomes null instead of being an
 undefined reference.
</p></td></tr><tr><td class="src"><a name="v:ExternallyVisible" class="def">ExternallyVisible</a></td><td class="doc"><p>The symbol participates in linkage and can be used to resolve external
  symbol references.
</p></td></tr><tr><td class="src"><a name="v:External" class="def">External</a></td><td class="doc"><p>Alias for <code><a href="Llvm.html#v:ExternallyVisible">ExternallyVisible</a></code> but with explicit textual form in LLVM
  assembly.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmLinkageType" class="caption collapser" onclick="toggleSection('i:LlvmLinkageType')">Instances</p><div id="section.i:LlvmLinkageType" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmFuncAttr" class="def">LlvmFuncAttr</a>  </p><div class="doc"><p>Llvm Function Attributes.
</p><p>Function attributes are set to communicate additional information about a
 function. Function attributes are considered to be part of the function,
 not of the function type, so functions with different parameter attributes
 can have the same function type. Functions can have multiple attributes.
</p><p>Descriptions taken from <a href="http://llvm.org/docs/LangRef.html#fnattrs">http://llvm.org/docs/LangRef.html#fnattrs</a>
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:AlwaysInline" class="def">AlwaysInline</a></td><td class="doc"><p>This attribute indicates that the inliner should attempt to inline this
 function into callers whenever possible, ignoring any active inlining
 size threshold for this caller.
</p></td></tr><tr><td class="src"><a name="v:InlineHint" class="def">InlineHint</a></td><td class="doc"><p>This attribute indicates that the source code contained a hint that
 inlining this function is desirable (such as the &quot;inline&quot; keyword in
 C/C++). It is just a hint; it imposes no requirements on the inliner.
</p></td></tr><tr><td class="src"><a name="v:NoInline" class="def">NoInline</a></td><td class="doc"><p>This attribute indicates that the inliner should never inline this
 function in any situation. This attribute may not be used together
 with the alwaysinline attribute.
</p></td></tr><tr><td class="src"><a name="v:OptSize" class="def">OptSize</a></td><td class="doc"><p>This attribute suggests that optimization passes and code generator
 passes make choices that keep the code size of this function low, and
 otherwise do optimizations specifically to reduce code size.
</p></td></tr><tr><td class="src"><a name="v:NoReturn" class="def">NoReturn</a></td><td class="doc"><p>This function attribute indicates that the function never returns
 normally. This produces undefined behavior at runtime if the function
 ever does dynamically return.
</p></td></tr><tr><td class="src"><a name="v:NoUnwind" class="def">NoUnwind</a></td><td class="doc"><p>This function attribute indicates that the function never returns with
 an unwind or exceptional control flow. If the function does unwind, its
 runtime behavior is undefined.
</p></td></tr><tr><td class="src"><a name="v:ReadNone" class="def">ReadNone</a></td><td class="doc"><p>This attribute indicates that the function computes its result (or
 decides to unwind an exception) based strictly on its arguments, without
 dereferencing any pointer arguments or otherwise accessing any mutable
 state (e.g. memory, control registers, etc) visible to caller functions.
 It does not write through any pointer arguments (including byval
 arguments) and never changes any state visible to callers. This means
 that it cannot unwind exceptions by calling the C++ exception throwing
 methods, but could use the unwind instruction.
</p></td></tr><tr><td class="src"><a name="v:ReadOnly" class="def">ReadOnly</a></td><td class="doc"><p>This attribute indicates that the function does not write through any
 pointer arguments (including byval arguments) or otherwise modify any
 state (e.g. memory, control registers, etc) visible to caller functions.
 It may dereference pointer arguments and read state that may be set in
 the caller. A readonly function always returns the same value (or unwinds
 an exception identically) when called with the same set of arguments and
 global state. It cannot unwind an exception by calling the C++ exception
 throwing methods, but may use the unwind instruction.
</p></td></tr><tr><td class="src"><a name="v:Ssp" class="def">Ssp</a></td><td class="doc"><p>This attribute indicates that the function should emit a stack smashing
 protector. It is in the form of a &quot;canary&quot;&#8212;a random value placed on the
 stack before the local variables that's checked upon return from the
 function to see if it has been overwritten. A heuristic is used to
 determine if a function needs stack protectors or not.
</p><p>If a function that has an ssp attribute is inlined into a function that
 doesn't have an ssp attribute, then the resulting function will have an
 ssp attribute.
</p></td></tr><tr><td class="src"><a name="v:SspReq" class="def">SspReq</a></td><td class="doc"><p>This attribute indicates that the function should always emit a stack
 smashing protector. This overrides the ssp function attribute.
</p><p>If a function that has an sspreq attribute is inlined into a function
 that doesn't have an sspreq attribute or which has an ssp attribute,
 then the resulting function will have an sspreq attribute.
</p></td></tr><tr><td class="src"><a name="v:NoRedZone" class="def">NoRedZone</a></td><td class="doc"><p>This attribute indicates that the code generator should not use a red
 zone, even if the target-specific ABI normally permits it.
</p></td></tr><tr><td class="src"><a name="v:NoImplicitFloat" class="def">NoImplicitFloat</a></td><td class="doc"><p>This attributes disables implicit floating point instructions.
</p></td></tr><tr><td class="src"><a name="v:Naked" class="def">Naked</a></td><td class="doc"><p>This attribute disables prologue / epilogue emission for the function.
 This can have very system-specific consequences.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmFuncAttr" class="caption collapser" onclick="toggleSection('i:LlvmFuncAttr')">Instances</p><div id="section.i:LlvmFuncAttr" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmFuncAttr">LlvmFuncAttr</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmFuncAttr">LlvmFuncAttr</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:4">Operations and Comparisons
</h1><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmCmpOp" class="def">LlvmCmpOp</a>  </p><div class="doc"><p>Llvm compare operations.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LM_CMP_Eq" class="def">LM_CMP_Eq</a></td><td class="doc"><p>Equal (Signed and Unsigned)
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Ne" class="def">LM_CMP_Ne</a></td><td class="doc"><p>Not equal (Signed and Unsigned)
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Ugt" class="def">LM_CMP_Ugt</a></td><td class="doc"><p>Unsigned greater than
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Uge" class="def">LM_CMP_Uge</a></td><td class="doc"><p>Unsigned greater than or equal
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Ult" class="def">LM_CMP_Ult</a></td><td class="doc"><p>Unsigned less than
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Ule" class="def">LM_CMP_Ule</a></td><td class="doc"><p>Unsigned less than or equal
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Sgt" class="def">LM_CMP_Sgt</a></td><td class="doc"><p>Signed greater than
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Sge" class="def">LM_CMP_Sge</a></td><td class="doc"><p>Signed greater than or equal
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Slt" class="def">LM_CMP_Slt</a></td><td class="doc"><p>Signed less than
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Sle" class="def">LM_CMP_Sle</a></td><td class="doc"><p>Signed less than or equal
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Feq" class="def">LM_CMP_Feq</a></td><td class="doc"><p>Float equal
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Fne" class="def">LM_CMP_Fne</a></td><td class="doc"><p>Float not equal
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Fgt" class="def">LM_CMP_Fgt</a></td><td class="doc"><p>Float greater than
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Fge" class="def">LM_CMP_Fge</a></td><td class="doc"><p>Float greater than or equal
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Flt" class="def">LM_CMP_Flt</a></td><td class="doc"><p>Float less than
</p></td></tr><tr><td class="src"><a name="v:LM_CMP_Fle" class="def">LM_CMP_Fle</a></td><td class="doc"><p>Float less than or equal
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmCmpOp" class="caption collapser" onclick="toggleSection('i:LlvmCmpOp')">Instances</p><div id="section.i:LlvmCmpOp" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmCmpOp">LlvmCmpOp</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmCmpOp">LlvmCmpOp</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmMachOp" class="def">LlvmMachOp</a>  </p><div class="doc"><p>Llvm binary operators machine operations.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LM_MO_Add" class="def">LM_MO_Add</a></td><td class="doc"><p>add two integer, floating point or vector values.
</p></td></tr><tr><td class="src"><a name="v:LM_MO_Sub" class="def">LM_MO_Sub</a></td><td class="doc"><p>subtract two ...
</p></td></tr><tr><td class="src"><a name="v:LM_MO_Mul" class="def">LM_MO_Mul</a></td><td class="doc"><p>multiply ..
</p></td></tr><tr><td class="src"><a name="v:LM_MO_UDiv" class="def">LM_MO_UDiv</a></td><td class="doc"><p>unsigned integer or vector division.
</p></td></tr><tr><td class="src"><a name="v:LM_MO_SDiv" class="def">LM_MO_SDiv</a></td><td class="doc"><p>signed integer ..
</p></td></tr><tr><td class="src"><a name="v:LM_MO_URem" class="def">LM_MO_URem</a></td><td class="doc"><p>unsigned integer or vector remainder (mod)
</p></td></tr><tr><td class="src"><a name="v:LM_MO_SRem" class="def">LM_MO_SRem</a></td><td class="doc"><p>signed ...
</p></td></tr><tr><td class="src"><a name="v:LM_MO_FAdd" class="def">LM_MO_FAdd</a></td><td class="doc"><p>add two floating point or vector values.
</p></td></tr><tr><td class="src"><a name="v:LM_MO_FSub" class="def">LM_MO_FSub</a></td><td class="doc"><p>subtract two ...
</p></td></tr><tr><td class="src"><a name="v:LM_MO_FMul" class="def">LM_MO_FMul</a></td><td class="doc"><p>multiply ...
</p></td></tr><tr><td class="src"><a name="v:LM_MO_FDiv" class="def">LM_MO_FDiv</a></td><td class="doc"><p>divide ...
</p></td></tr><tr><td class="src"><a name="v:LM_MO_FRem" class="def">LM_MO_FRem</a></td><td class="doc"><p>remainder ...
</p></td></tr><tr><td class="src"><a name="v:LM_MO_Shl" class="def">LM_MO_Shl</a></td><td class="doc"><p>Left shift
</p></td></tr><tr><td class="src"><a name="v:LM_MO_LShr" class="def">LM_MO_LShr</a></td><td class="doc"><p>Logical shift right
 Shift right, filling with zero
</p></td></tr><tr><td class="src"><a name="v:LM_MO_AShr" class="def">LM_MO_AShr</a></td><td class="doc"><p>Arithmetic shift right
 The most significant bits of the result will be equal to the sign bit of
 the left operand.
</p></td></tr><tr><td class="src"><a name="v:LM_MO_And" class="def">LM_MO_And</a></td><td class="doc"><p>AND bitwise logical operation.
</p></td></tr><tr><td class="src"><a name="v:LM_MO_Or" class="def">LM_MO_Or</a></td><td class="doc"><p>OR bitwise logical operation.
</p></td></tr><tr><td class="src"><a name="v:LM_MO_Xor" class="def">LM_MO_Xor</a></td><td class="doc"><p>XOR bitwise logical operation.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmMachOp" class="caption collapser" onclick="toggleSection('i:LlvmMachOp')">Instances</p><div id="section.i:LlvmMachOp" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmMachOp">LlvmMachOp</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmMachOp">LlvmMachOp</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmCastOp" class="def">LlvmCastOp</a>  </p><div class="doc"><p>Llvm cast operations.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LM_Trunc" class="def">LM_Trunc</a></td><td class="doc"><p>Integer truncate
</p></td></tr><tr><td class="src"><a name="v:LM_Zext" class="def">LM_Zext</a></td><td class="doc"><p>Integer extend (zero fill)
</p></td></tr><tr><td class="src"><a name="v:LM_Sext" class="def">LM_Sext</a></td><td class="doc"><p>Integer extend (sign fill)
</p></td></tr><tr><td class="src"><a name="v:LM_Fptrunc" class="def">LM_Fptrunc</a></td><td class="doc"><p>Float truncate
</p></td></tr><tr><td class="src"><a name="v:LM_Fpext" class="def">LM_Fpext</a></td><td class="doc"><p>Float extend
</p></td></tr><tr><td class="src"><a name="v:LM_Fptoui" class="def">LM_Fptoui</a></td><td class="doc"><p>Float to unsigned Integer
</p></td></tr><tr><td class="src"><a name="v:LM_Fptosi" class="def">LM_Fptosi</a></td><td class="doc"><p>Float to signed Integer
</p></td></tr><tr><td class="src"><a name="v:LM_Uitofp" class="def">LM_Uitofp</a></td><td class="doc"><p>Unsigned Integer to Float
</p></td></tr><tr><td class="src"><a name="v:LM_Sitofp" class="def">LM_Sitofp</a></td><td class="doc"><p>Signed Int to Float
</p></td></tr><tr><td class="src"><a name="v:LM_Ptrtoint" class="def">LM_Ptrtoint</a></td><td class="doc"><p>Pointer to Integer
</p></td></tr><tr><td class="src"><a name="v:LM_Inttoptr" class="def">LM_Inttoptr</a></td><td class="doc"><p>Integer to Pointer
</p></td></tr><tr><td class="src"><a name="v:LM_Bitcast" class="def">LM_Bitcast</a></td><td class="doc"><p>Cast between types where no bit manipulation is needed
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmCastOp" class="caption collapser" onclick="toggleSection('i:LlvmCastOp')">Instances</p><div id="section.i:LlvmCastOp" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmCastOp">LlvmCastOp</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmCastOp">LlvmCastOp</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:5">Variables and Type System
</h1><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmVar" class="def">LlvmVar</a>  </p><div class="doc"><p>Llvm Variables
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LMGlobalVar" class="def">LMGlobalVar</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LlvmType">LlvmType</a> <a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a> <a href="Llvm.html#t:LMSection">LMSection</a> <a href="Llvm.html#t:LMAlign">LMAlign</a> <a href="Llvm-Types.html#t:LMConst">LMConst</a></td><td class="doc"><p>Variables with a global scope.
</p></td></tr><tr><td class="src"><a name="v:LMLocalVar" class="def">LMLocalVar</a> <a href="Unique.html#t:Unique">Unique</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Variables local to a function or parameters.
</p></td></tr><tr><td class="src"><a name="v:LMNLocalVar" class="def">LMNLocalVar</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Named local variables. Sometimes we need to be able to explicitly name
 variables (e.g for function arguments).
</p></td></tr><tr><td class="src"><a name="v:LMLitVar" class="def">LMLitVar</a> <a href="Llvm.html#t:LlvmLit">LlvmLit</a></td><td class="doc"><p>A constant variable
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmVar" class="caption collapser" onclick="toggleSection('i:LlvmVar')">Instances</p><div id="section.i:LlvmVar" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmStatic" class="def">LlvmStatic</a>  </p><div class="doc"><p>Llvm Static Data.
</p><p>These represent the possible global level variables and constants.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LMComment" class="def">LMComment</a> <a href="Llvm.html#t:LMString">LMString</a></td><td class="doc"><p>A comment in a static section
</p></td></tr><tr><td class="src"><a name="v:LMStaticLit" class="def">LMStaticLit</a> <a href="Llvm.html#t:LlvmLit">LlvmLit</a></td><td class="doc"><p>A static variant of a literal value
</p></td></tr><tr><td class="src"><a name="v:LMUninitType" class="def">LMUninitType</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>For uninitialised data
</p></td></tr><tr><td class="src"><a name="v:LMStaticStr" class="def">LMStaticStr</a> <a href="Llvm.html#t:LMString">LMString</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Defines a static <code><a href="Llvm.html#t:LMString">LMString</a></code>
</p></td></tr><tr><td class="src"><a name="v:LMStaticArray" class="def">LMStaticArray</a> [<a href="Llvm.html#t:LlvmStatic">LlvmStatic</a>] <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>A static array
</p></td></tr><tr><td class="src"><a name="v:LMStaticStruc" class="def">LMStaticStruc</a> [<a href="Llvm.html#t:LlvmStatic">LlvmStatic</a>] <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>A static structure type
</p></td></tr><tr><td class="src"><a name="v:LMStaticPointer" class="def">LMStaticPointer</a> <a href="Llvm.html#t:LlvmVar">LlvmVar</a></td><td class="doc"><p>A pointer to other data
</p></td></tr><tr><td class="src"><a name="v:LMBitc" class="def">LMBitc</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Pointer to Pointer conversion
</p></td></tr><tr><td class="src"><a name="v:LMPtoI" class="def">LMPtoI</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Pointer to Integer conversion
</p></td></tr><tr><td class="src"><a name="v:LMAdd" class="def">LMAdd</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a></td><td class="doc"><p>Constant addition operation
</p></td></tr><tr><td class="src"><a name="v:LMSub" class="def">LMSub</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a></td><td class="doc"><p>Constant subtraction operation
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmStatic" class="caption collapser" onclick="toggleSection('i:LlvmStatic')">Instances</p><div id="section.i:LlvmStatic" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmLit" class="def">LlvmLit</a>  </p><div class="doc"><p>Llvm Literal Data.
</p><p>These can be used inline in expressions.
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LMIntLit" class="def">LMIntLit</a> <a href="../base-4.5.1.0/Prelude.html#t:Integer">Integer</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Refers to an integer constant (i64 42).
</p></td></tr><tr><td class="src"><a name="v:LMFloatLit" class="def">LMFloatLit</a> <a href="../base-4.5.1.0/Prelude.html#t:Double">Double</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Floating point literal
</p></td></tr><tr><td class="src"><a name="v:LMNullLit" class="def">LMNullLit</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Literal NULL, only applicable to pointer types
</p></td></tr><tr><td class="src"><a name="v:LMUndefLit" class="def">LMUndefLit</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>Undefined value, random bit pattern. Useful for optimisations.
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmLit" class="caption collapser" onclick="toggleSection('i:LlvmLit')">Instances</p><div id="section.i:LlvmLit" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmLit">LlvmLit</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmLit">LlvmLit</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span>  <a name="t:LlvmType" class="def">LlvmType</a>  </p><div class="doc"><p>Llvm Types
</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:LMInt" class="def">LMInt</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a></td><td class="doc"><p>An integer with a given width in bits.
</p></td></tr><tr><td class="src"><a name="v:LMFloat" class="def">LMFloat</a></td><td class="doc"><p>32 bit floating point
</p></td></tr><tr><td class="src"><a name="v:LMDouble" class="def">LMDouble</a></td><td class="doc"><p>64 bit floating point
</p></td></tr><tr><td class="src"><a name="v:LMFloat80" class="def">LMFloat80</a></td><td class="doc"><p>80 bit (x86 only) floating point
</p></td></tr><tr><td class="src"><a name="v:LMFloat128" class="def">LMFloat128</a></td><td class="doc"><p>128 bit floating point
</p></td></tr><tr><td class="src"><a name="v:LMPointer" class="def">LMPointer</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>A pointer to a <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code>
</p></td></tr><tr><td class="src"><a name="v:LMArray" class="def">LMArray</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc"><p>An array of <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code>
</p></td></tr><tr><td class="src"><a name="v:LMLabel" class="def">LMLabel</a></td><td class="doc"><p>A <code><a href="Llvm.html#t:LlvmVar">LlvmVar</a></code> can represent a label (address)
</p></td></tr><tr><td class="src"><a name="v:LMVoid" class="def">LMVoid</a></td><td class="doc"><p>Void type
</p></td></tr><tr><td class="src"><a name="v:LMStruct" class="def">LMStruct</a> [<a href="Llvm.html#t:LlvmType">LlvmType</a>]</td><td class="doc"><p>Structure type
</p></td></tr><tr><td class="src"><a name="v:LMAlias" class="def">LMAlias</a> <a href="Llvm.html#t:LlvmAlias">LlvmAlias</a></td><td class="doc"><p>A type alias
</p></td></tr><tr><td class="src"><a name="v:LMFunction" class="def">LMFunction</a> <a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a></td><td class="doc"><p>Function type, used to create pointers to functions
</p></td></tr></table></div><div class="subs instances"><p id="control.i:LlvmType" class="caption collapser" onclick="toggleSection('i:LlvmType')">Instances</p><div id="section.i:LlvmType" class="show"><table><tr><td class="src"><a href="../base-4.5.1.0/Data-Eq.html#t:Eq">Eq</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="../base-4.5.1.0/Text-Show.html#t:Show">Show</a> <a href="Llvm.html#t:LlvmType">LlvmType</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LlvmAlias" class="def">LlvmAlias</a> = (<a href="Llvm.html#t:LMString">LMString</a>, <a href="Llvm.html#t:LlvmType">LlvmType</a>)</p><div class="doc"><p>A type alias
</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LMGlobal" class="def">LMGlobal</a> = (<a href="Llvm.html#t:LlvmVar">LlvmVar</a>, <a href="../base-4.5.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a>)</p><div class="doc"><p>A global mutable variable. Maybe defined or external
</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LMString" class="def">LMString</a> = <a href="FastString.html#t:FastString">FastString</a></p><div class="doc"><p>A String in LLVM
</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LMSection" class="def">LMSection</a> = <a href="../base-4.5.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="Llvm.html#t:LMString">LMString</a></p><div class="doc"><p>An LLVM section definition. If Nothing then let LLVM decide the section
</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LMAlign" class="def">LMAlign</a> = <a href="../base-4.5.1.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a></p></div><h2 id="g:6">Some basic types
</h2><div class="top"><p class="src"><a name="v:i64" class="def">i64</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></p></div><div class="top"><p class="src"><a name="v:i32" class="def">i32</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></p></div><div class="top"><p class="src"><a name="v:i16" class="def">i16</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></p></div><div class="top"><p class="src"><a name="v:i8" class="def">i8</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></p></div><div class="top"><p class="src"><a name="v:i1" class="def">i1</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></p></div><div class="top"><p class="src"><a name="v:i8Ptr" class="def">i8Ptr</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></p></div><div class="top"><p class="src"><a name="v:llvmWord" class="def">llvmWord</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></p><div class="doc"><p>The target architectures word size
</p></div></div><div class="top"><p class="src"><a name="v:llvmWordPtr" class="def">llvmWordPtr</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a></p><div class="doc"><p>The target architectures word size
</p></div></div><h2 id="g:7">Operations on the type system.
</h2><div class="top"><p class="src"><a name="v:isGlobal" class="def">isGlobal</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Test if a <code><a href="Llvm.html#t:LlvmVar">LlvmVar</a></code> is global.
</p></div></div><div class="top"><p class="src"><a name="v:getLitType" class="def">getLitType</a> :: <a href="Llvm.html#t:LlvmLit">LlvmLit</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></p><div class="doc"><p>Return the <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code> of a <code><a href="Llvm.html#t:LlvmLit">LlvmLit</a></code>
</p></div></div><div class="top"><p class="src"><a name="v:getLit" class="def">getLit</a> :: <a href="Llvm.html#t:LlvmLit">LlvmLit</a> -&gt; <a href="../base-4.5.1.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Print a literal value. No type.
</p></div></div><div class="top"><p class="src"><a name="v:getName" class="def">getName</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="../base-4.5.1.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Return the variable name or value of the <code><a href="Llvm.html#t:LlvmVar">LlvmVar</a></code>
 in Llvm IR textual representation (e.g. <code>@x</code>, <code>%y</code> or <code>42</code>).
</p></div></div><div class="top"><p class="src"><a name="v:getPlainName" class="def">getPlainName</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="../base-4.5.1.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Return the variable name or value of the <code><a href="Llvm.html#t:LlvmVar">LlvmVar</a></code>
 in a plain textual representation (e.g. <code>x</code>, <code>y</code> or <code>42</code>).
</p></div></div><div class="top"><p class="src"><a name="v:getVarType" class="def">getVarType</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></p><div class="doc"><p>Return the <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code> of the <code><a href="Llvm.html#t:LlvmVar">LlvmVar</a></code>
</p></div></div><div class="top"><p class="src"><a name="v:getLink" class="def">getLink</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a></p><div class="doc"><p>Return the <code><a href="Llvm.html#t:LlvmLinkageType">LlvmLinkageType</a></code> for a <code><a href="Llvm.html#t:LlvmVar">LlvmVar</a></code>
</p></div></div><div class="top"><p class="src"><a name="v:getStatType" class="def">getStatType</a> :: <a href="Llvm.html#t:LlvmStatic">LlvmStatic</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></p><div class="doc"><p>Return the <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code> of the <code><a href="Llvm.html#t:LlvmStatic">LlvmStatic</a></code>
</p></div></div><div class="top"><p class="src"><a name="v:getGlobalVar" class="def">getGlobalVar</a> :: <a href="Llvm.html#t:LMGlobal">LMGlobal</a> -&gt; <a href="Llvm.html#t:LlvmVar">LlvmVar</a></p><div class="doc"><p>Return the <code><a href="Llvm.html#t:LlvmVar">LlvmVar</a></code> part of a <code><a href="Llvm.html#t:LMGlobal">LMGlobal</a></code>
</p></div></div><div class="top"><p class="src"><a name="v:getGlobalType" class="def">getGlobalType</a> :: <a href="Llvm.html#t:LMGlobal">LMGlobal</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></p><div class="doc"><p>Return the <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code> of the <code><a href="Llvm.html#t:LMGlobal">LMGlobal</a></code>
</p></div></div><div class="top"><p class="src"><a name="v:pVarLift" class="def">pVarLift</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="Llvm.html#t:LlvmVar">LlvmVar</a></p><div class="doc"><p>Lower a variable of <code><a href="Llvm.html#v:LMPointer">LMPointer</a></code> type.
</p></div></div><div class="top"><p class="src"><a name="v:pVarLower" class="def">pVarLower</a> :: <a href="Llvm.html#t:LlvmVar">LlvmVar</a> -&gt; <a href="Llvm.html#t:LlvmVar">LlvmVar</a></p><div class="doc"><p>Lower a variable of <code><a href="Llvm.html#v:LMPointer">LMPointer</a></code> type.
</p></div></div><div class="top"><p class="src"><a name="v:pLift" class="def">pLift</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></p><div class="doc"><p>Add a pointer indirection to the supplied type. <code><a href="Llvm.html#v:LMLabel">LMLabel</a></code> and <code><a href="Llvm.html#v:LMVoid">LMVoid</a></code>
 cannot be lifted.
</p></div></div><div class="top"><p class="src"><a name="v:pLower" class="def">pLower</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="Llvm.html#t:LlvmType">LlvmType</a></p><div class="doc"><p>Remove the pointer indirection of the supplied type. Only <code><a href="Llvm.html#v:LMPointer">LMPointer</a></code>
 constructors can be lowered.
</p></div></div><div class="top"><p class="src"><a name="v:isInt" class="def">isInt</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Test if the given <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code> is an integer
</p></div></div><div class="top"><p class="src"><a name="v:isFloat" class="def">isFloat</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Test if the given <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code> is a floating point type
</p></div></div><div class="top"><p class="src"><a name="v:isPointer" class="def">isPointer</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="../base-4.5.1.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Test if the given <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code> is an <code><a href="Llvm.html#v:LMPointer">LMPointer</a></code> construct
</p></div></div><div class="top"><p class="src"><a name="v:llvmWidthInBits" class="def">llvmWidthInBits</a> :: <a href="Llvm.html#t:LlvmType">LlvmType</a> -&gt; <a href="../base-4.5.1.0/Data-Int.html#t:Int">Int</a></p><div class="doc"><p>Width in bits of an <code><a href="Llvm.html#t:LlvmType">LlvmType</a></code>, returns 0 if not applicable
</p></div></div><h1 id="g:8">Pretty Printing
</h1><div class="top"><p class="src"><a name="v:ppLlvmModule" class="def">ppLlvmModule</a> :: <a href="Llvm.html#t:LlvmModule">LlvmModule</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a whole LLVM module.
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmComments" class="def">ppLlvmComments</a> :: [<a href="Llvm.html#t:LMString">LMString</a>] -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a multi-line comment, can be inside a function or on its own
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmComment" class="def">ppLlvmComment</a> :: <a href="Llvm.html#t:LMString">LMString</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a comment, can be inside a function or on its own
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmGlobals" class="def">ppLlvmGlobals</a> :: [<a href="Llvm.html#t:LMGlobal">LMGlobal</a>] -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a list of global mutable variable definitions
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmGlobal" class="def">ppLlvmGlobal</a> :: <a href="Llvm.html#t:LMGlobal">LMGlobal</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a global mutable variable definition
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmFunctionDecls" class="def">ppLlvmFunctionDecls</a> :: <a href="Llvm.html#t:LlvmFunctionDecls">LlvmFunctionDecls</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a list of function declaration.
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmFunctionDecl" class="def">ppLlvmFunctionDecl</a> :: <a href="Llvm.html#t:LlvmFunctionDecl">LlvmFunctionDecl</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a function declaration.
 Declarations define the function type but don't define the actual body of
 the function.
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmFunctions" class="def">ppLlvmFunctions</a> :: <a href="Llvm.html#t:LlvmFunctions">LlvmFunctions</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a list of function definitions.
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmFunction" class="def">ppLlvmFunction</a> :: <a href="Llvm.html#t:LlvmFunction">LlvmFunction</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a function definition.
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmAlias" class="def">ppLlvmAlias</a> :: <a href="Llvm.html#t:LlvmAlias">LlvmAlias</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out an LLVM type alias.
</p></div></div><div class="top"><p class="src"><a name="v:ppLlvmAliases" class="def">ppLlvmAliases</a> :: [<a href="Llvm.html#t:LlvmAlias">LlvmAlias</a>] -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Print out a list of LLVM type aliases.
</p></div></div><div class="top"><p class="src"><a name="v:llvmSDoc" class="def">llvmSDoc</a> :: <a href="Outputable.html#t:SDoc">SDoc</a> -&gt; <a href="Pretty.html#t:Doc">Doc</a></p><div class="doc"><p>Convert SDoc to Doc
</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.11.0</p></div></body></html>