diff options
author | Torok Edwin <edwintorok@gmail.com> | 2011-10-14 20:37:56 +0000 |
---|---|---|
committer | Torok Edwin <edwintorok@gmail.com> | 2011-10-14 20:37:56 +0000 |
commit | 3dd16741864302af14b31b7f75375c09d8544a35 (patch) | |
tree | c80cc3a242d87e61d7cbc607118600240e5138a0 /bindings/ocaml/llvm/llvm.mli | |
parent | 6563c879964c3bcf5c77d40da8d4c807adf605aa (diff) | |
download | llvm-3dd16741864302af14b31b7f75375c09d8544a35.tar.gz llvm-3dd16741864302af14b31b7f75375c09d8544a35.tar.bz2 llvm-3dd16741864302af14b31b7f75375c09d8544a35.tar.xz |
ocaml bindings: introduce classify_value
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141991 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'bindings/ocaml/llvm/llvm.mli')
-rw-r--r-- | bindings/ocaml/llvm/llvm.mli | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/bindings/ocaml/llvm/llvm.mli b/bindings/ocaml/llvm/llvm.mli index 2e2db6e531..2cfafdc89a 100644 --- a/bindings/ocaml/llvm/llvm.mli +++ b/bindings/ocaml/llvm/llvm.mli @@ -251,6 +251,31 @@ module Opcode : sig | Unwind end +(** The kind of an [llvalue], the result of [classify_value v]. + * See the various [LLVMIsA*] functions. *) +module ValueKind : sig + type t = + | NullValue + | Argument + | BasicBlock + | InlineAsm + | MDNode + | MDString + | BlockAddress + | ConstantAggregateZero + | ConstantArray + | ConstantExpr + | ConstantFP + | ConstantInt + | ConstantPointerNull + | ConstantStruct + | ConstantVector + | Function + | GlobalAlias + | GlobalVariable + | UndefValue + | Instruction of Opcode.t +end (** {6 Iteration} *) @@ -518,6 +543,8 @@ val label_type : llcontext -> lltype See the method [llvm::Value::getType]. *) val type_of : llvalue -> lltype +val classify_value : llvalue -> ValueKind.t + (** [value_name v] returns the name of the value [v]. For global values, this is the symbol name. For instructions and basic blocks, it is the SSA register name. It is meaningless for constants. |