summaryrefslogtreecommitdiffstats
path: root/llvm/include/llvm-c/Target.h
diff options
context:
space:
mode:
authorAmaury Sechet <deadalnix@gmail.com>2016-02-16 05:11:24 +0000
committerAmaury Sechet <deadalnix@gmail.com>2016-02-16 05:11:24 +0000
commit5590967610afa5fcc79386e08acc4d0fad5b6b9f (patch)
tree79b584bf548d4bc6d19e0656121a58dcb5870757 /llvm/include/llvm-c/Target.h
parent6615654f565c3a19f1f8a6e74ccdc723fd0c71d3 (diff)
downloadbcm5719-llvm-5590967610afa5fcc79386e08acc4d0fad5b6b9f.tar.gz
bcm5719-llvm-5590967610afa5fcc79386e08acc4d0fad5b6b9f.zip
Restore the capability to manipulate datalayout from the C API
Summary: This consist in variosu addition to the C API: LLVMTargetDataRef LLVMGetModuleDataLayout(LLVMModuleRef M); void LLVMSetModuleDataLayout(LLVMModuleRef M, LLVMTargetDataRef DL); LLVMTargetDataRef LLVMCreateTargetMachineData(LLVMTargetMachineRef T); Reviewers: joker.eph, Wallbraker, echristo Subscribers: axw Differential Revision: http://reviews.llvm.org/D17255 llvm-svn: 260936
Diffstat (limited to 'llvm/include/llvm-c/Target.h')
-rw-r--r--llvm/include/llvm-c/Target.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/include/llvm-c/Target.h b/llvm/include/llvm-c/Target.h
index 2b969e24a18..f2a2b18cc05 100644
--- a/llvm/include/llvm-c/Target.h
+++ b/llvm/include/llvm-c/Target.h
@@ -183,6 +183,20 @@ static inline LLVMBool LLVMInitializeNativeDisassembler(void) {
/*===-- Target Data -------------------------------------------------------===*/
+/**
+ * Obtain the data layout for a module.
+ *
+ * @see Module::getDataLayout()
+ */
+LLVMTargetDataRef LLVMGetModuleDataLayout(LLVMModuleRef M);
+
+/**
+ * Set the data layout for a module.
+ *
+ * @see Module::setDataLayout()
+ */
+void LLVMSetModuleDataLayout(LLVMModuleRef M, LLVMTargetDataRef DL);
+
/** Creates target data from a target layout string.
See the constructor llvm::DataLayout::DataLayout. */
LLVMTargetDataRef LLVMCreateTargetData(const char *StringRep);
OpenPOWER on IntegriCloud