aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/IR/Function.cpp
diff options
context:
space:
mode:
authorArthur Eubanks <aeubanks@google.com>2020-04-29 18:50:17 -0700
committerArthur Eubanks <aeubanks@google.com>2020-04-30 09:42:13 -0700
commita90948fd6e3bbac6ae63a34f52882e036b2dd032 (patch)
treeb5ac41ac1f7c69c2e36790d430a50fc860e8e4ed /llvm/lib/IR/Function.cpp
parent4eabd006125424f879a7129eca824998192d89a9 (diff)
downloadllvm-a90948fd6e3bbac6ae63a34f52882e036b2dd032.zip
llvm-a90948fd6e3bbac6ae63a34f52882e036b2dd032.tar.gz
llvm-a90948fd6e3bbac6ae63a34f52882e036b2dd032.tar.bz2
[NFC] Rename *ByValOrInalloca* to *PassPointeeByValue*
Summary: In preparation for preallocated. Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D79152
Diffstat (limited to 'llvm/lib/IR/Function.cpp')
-rw-r--r--llvm/lib/IR/Function.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/lib/IR/Function.cpp b/llvm/lib/IR/Function.cpp
index 77e0f3f..ac62ffa 100644
--- a/llvm/lib/IR/Function.cpp
+++ b/llvm/lib/IR/Function.cpp
@@ -114,11 +114,12 @@ bool Argument::hasInAllocaAttr() const {
return hasAttribute(Attribute::InAlloca);
}
-bool Argument::hasByValOrInAllocaAttr() const {
+bool Argument::hasPassPointeeByValueAttr() const {
if (!getType()->isPointerTy()) return false;
AttributeList Attrs = getParent()->getAttributes();
return Attrs.hasParamAttribute(getArgNo(), Attribute::ByVal) ||
- Attrs.hasParamAttribute(getArgNo(), Attribute::InAlloca);
+ Attrs.hasParamAttribute(getArgNo(), Attribute::InAlloca) ||
+ Attrs.hasParamAttribute(getArgNo(), Attribute::Preallocated);
}
unsigned Argument::getParamAlignment() const {