diff options
Diffstat (limited to 'llvm/lib/IR/Core.cpp')
-rw-r--r-- | llvm/lib/IR/Core.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/IR/Core.cpp b/llvm/lib/IR/Core.cpp index d8dfcc8c916..ab7a7471d46 100644 --- a/llvm/lib/IR/Core.cpp +++ b/llvm/lib/IR/Core.cpp @@ -2012,7 +2012,7 @@ void LLVMSetAlignment(LLVMValueRef V, unsigned Bytes) { else if (AllocaInst *AI = dyn_cast<AllocaInst>(P)) AI->setAlignment(Bytes); else if (LoadInst *LI = dyn_cast<LoadInst>(P)) - LI->setAlignment(Bytes); + LI->setAlignment(MaybeAlign(Bytes)); else if (StoreInst *SI = dyn_cast<StoreInst>(P)) SI->setAlignment(Bytes); else |