summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/InstCombine
diff options
context:
space:
mode:
authorReid Kleckner <rnk@google.com>2017-04-12 00:38:00 +0000
committerReid Kleckner <rnk@google.com>2017-04-12 00:38:00 +0000
commitc2cb5600450b8c4e5fdd915bd8c848319c5e57e1 (patch)
tree621b8f69c41b1b0aead20855cdede8ddd54eae70 /llvm/lib/Transforms/InstCombine
parentbdbdd229375f1b7c112bb5ecef8aeb603ad8d07f (diff)
downloadbcm5719-llvm-c2cb5600450b8c4e5fdd915bd8c848319c5e57e1.tar.gz
bcm5719-llvm-c2cb5600450b8c4e5fdd915bd8c848319c5e57e1.zip
[IR] Add AttributeSet to hide AttributeSetNode* again, NFC
Summary: For now, it just wraps AttributeSetNode*. Eventually, it will hold AvailableAttrs as an inline bitset, and adding and removing enum attributes will be super cheap. This sinks AttributeSetNode back down to lib/IR/AttributeImpl.h. Reviewers: pete, chandlerc Subscribers: llvm-commits, jfb Differential Revision: https://reviews.llvm.org/D31940 llvm-svn: 300014
Diffstat (limited to 'llvm/lib/Transforms/InstCombine')
-rw-r--r--llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp b/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
index c850e2e7393..cdae9571851 100644
--- a/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
+++ b/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
@@ -23,7 +23,6 @@
#include "llvm/Analysis/InstructionSimplify.h"
#include "llvm/Analysis/MemoryBuiltins.h"
#include "llvm/Analysis/ValueTracking.h"
-#include "llvm/IR/AttributeSetNode.h"
#include "llvm/IR/BasicBlock.h"
#include "llvm/IR/CallSite.h"
#include "llvm/IR/Constant.h"
@@ -4119,7 +4118,7 @@ bool InstCombiner::transformConstExprCastCall(CallSite CS) {
}
}
- AttributeSetNode *FnAttrs = CallerPAL.getFnAttributes();
+ AttributeSet FnAttrs = CallerPAL.getFnAttributes();
if (CallerPAL.hasAttributes(AttributeList::FunctionIndex))
attrVec.push_back(AttributeList::get(Callee->getContext(),
AttributeList::FunctionIndex,
@@ -4218,7 +4217,7 @@ InstCombiner::transformCallThroughTrampoline(CallSite CS,
if (!NestAttrs.isEmpty()) {
unsigned NestIdx = 1;
Type *NestTy = nullptr;
- AttributeSetNode *NestAttr;
+ AttributeSet NestAttr;
// Look for a parameter marked with the 'nest' attribute.
for (FunctionType::param_iterator I = NestFTy->param_begin(),
@@ -4233,7 +4232,7 @@ InstCombiner::transformCallThroughTrampoline(CallSite CS,
if (NestTy) {
Instruction *Caller = CS.getInstruction();
std::vector<Value*> NewArgs;
- std::vector<AttributeSetNode *> NewAttrs;
+ std::vector<AttributeSet> NewAttrs;
NewArgs.reserve(CS.arg_size() + 1);
NewAttrs.reserve(CS.arg_size() + 2);
OpenPOWER on IntegriCloud