diff options
author | Anders Waldenborg <anders@0x63.nu> | 2013-10-29 09:02:02 +0000 |
---|---|---|
committer | Anders Waldenborg <anders@0x63.nu> | 2013-10-29 09:02:02 +0000 |
commit | 213a63fe53fc93f2cb3ba3b70048e6599350f24b (patch) | |
tree | 15b9bbc67019a1eb380ec58ad75f98a996bfed46 /llvm/include/llvm-c | |
parent | 4952448b5672027deecc8808a5510b20a3b5293f (diff) | |
download | bcm5719-llvm-213a63fe53fc93f2cb3ba3b70048e6599350f24b.tar.gz bcm5719-llvm-213a63fe53fc93f2cb3ba3b70048e6599350f24b.zip |
llvm-c: Make LLVM{Get,Set}Alignment work on {Load,Store}Inst too
Patch by Peter Zotov
Differential Revision: http://llvm-reviews.chandlerc.com/D1910
llvm-svn: 193597
Diffstat (limited to 'llvm/include/llvm-c')
-rw-r--r-- | llvm/include/llvm-c/Core.h | 29 |
1 files changed, 27 insertions, 2 deletions
diff --git a/llvm/include/llvm-c/Core.h b/llvm/include/llvm-c/Core.h index b9bae7e7f26..004492b6ce0 100644 --- a/llvm/include/llvm-c/Core.h +++ b/llvm/include/llvm-c/Core.h @@ -1665,8 +1665,33 @@ const char *LLVMGetSection(LLVMValueRef Global); void LLVMSetSection(LLVMValueRef Global, const char *Section); LLVMVisibility LLVMGetVisibility(LLVMValueRef Global); void LLVMSetVisibility(LLVMValueRef Global, LLVMVisibility Viz); -unsigned LLVMGetAlignment(LLVMValueRef Global); -void LLVMSetAlignment(LLVMValueRef Global, unsigned Bytes); + +/** + * @defgroup LLVMCCoreValueWithAlignment Values with alignment + * + * Functions in this group only apply to values with alignment, i.e. + * global variables, load and store instructions. + */ + +/** + * Obtain the preferred alignment of the value. + * @see llvm::LoadInst::getAlignment() + * @see llvm::StoreInst::getAlignment() + * @see llvm::GlobalValue::getAlignment() + */ +unsigned LLVMGetAlignment(LLVMValueRef V); + +/** + * Set the preferred alignment of the value. + * @see llvm::LoadInst::setAlignment() + * @see llvm::StoreInst::setAlignment() + * @see llvm::GlobalValue::setAlignment() + */ +void LLVMSetAlignment(LLVMValueRef V, unsigned Bytes); + +/** + * @} + */ /** * @defgroup LLVMCoreValueConstantGlobalVariable Global Variables |