aboutsummaryrefslogtreecommitdiff
path: root/lib/IR/Attributes.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/IR/Attributes.cpp')
-rw-r--r--lib/IR/Attributes.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/IR/Attributes.cpp b/lib/IR/Attributes.cpp
index bef7a6c174..01a59a33c0 100644
--- a/lib/IR/Attributes.cpp
+++ b/lib/IR/Attributes.cpp
@@ -509,6 +509,14 @@ void AttributeImpl::setStackAlignment(unsigned Align) {
Vals.push_back(ConstantInt::get(Type::getInt64Ty(Context), Align));
}
+void Profile(FoldingSetNodeID &ID, Constant *Data,
+ ArrayRef<Constant*> Vals) {
+ ID.AddInteger(cast<ConstantInt>(Data)->getZExtValue());
+ for (ArrayRef<Constant*>::iterator I = Vals.begin(), E = Vals.end();
+ I != E; ++I)
+ ID.AddPointer(*I);
+}
+
//===----------------------------------------------------------------------===//
// AttributeSetImpl Definition
//===----------------------------------------------------------------------===//