llvm.org GIT mirror llvm / 39f6e73
[OCaml] Add Llvm.mdnull. Patch by Gideon Smeding <gideon.smeding@3ds.com>. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@223129 91177308-0d34-0410-b5e6-96231b3b80d8 Peter Zotov 4 years ago
3 changed file(s) with 9 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
458458 (*--... Operations on metadata .......,.....................................--*)
459459 external mdstring : llcontext -> string -> llvalue = "llvm_mdstring"
460460 external mdnode : llcontext -> llvalue array -> llvalue = "llvm_mdnode"
461 external mdnull : llcontext -> llvalue = "llvm_mdnull"
461462 external get_mdstring : llvalue -> string option = "llvm_get_mdstring"
462463 external get_named_metadata : llmodule -> string -> llvalue array
463464 = "llvm_get_namedmd"
818818 See the method [llvm::MDNode::get]. *)
819819 val mdnode : llcontext -> llvalue array -> llvalue
820820
821 (** [mdnull c ] returns a null MDNode in context [c]. *)
822 val mdnull : llcontext -> llvalue
823
821824 (** [get_mdstring v] returns the MDString.
822825 See the method [llvm::MDString::getString] *)
823826 val get_mdstring : llvalue -> string option
665665 Wosize_val(ElementVals));
666666 }
667667
668 /* llcontext -> llvalue */
669 CAMLprim LLVMValueRef llvm_mdnull(LLVMContextRef C) {
670 return NULL;
671 }
672
668673 /* llvalue -> string option */
669674 CAMLprim value llvm_get_mdstring(LLVMValueRef V) {
670675 CAMLparam0();