[llvm-commits] [llvm] r171923 - in /llvm/trunk: include/llvm/Attributes.h lib/IR/AttributeImpl.h lib/IR/Attributes.cpp
Bill Wendling
isanbard at gmail.com
Tue Jan 8 16:32:08 PST 2013
Author: void
Date: Tue Jan 8 18:32:08 2013
New Revision: 171923
URL: http://llvm.org/viewvc/llvm-project?rev=171923&view=rev
Log:
Add the integer value of the ConstantInt instead of the Constant* value.
This is causing some problems. The root cause is unknown at this time.
Added:
llvm/trunk/include/llvm/Attributes.h
- copied, changed from r171295, llvm/trunk/include/llvm/Attributes.h
Modified:
llvm/trunk/lib/IR/AttributeImpl.h
llvm/trunk/lib/IR/Attributes.cpp
Copied: llvm/trunk/include/llvm/Attributes.h (from r171295, llvm/trunk/include/llvm/Attributes.h)
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Attributes.h?p2=llvm/trunk/include/llvm/Attributes.h&p1=llvm/trunk/include/llvm/Attributes.h&r1=171295&r2=171923&rev=171923&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Attributes.h (original)
+++ llvm/trunk/include/llvm/Attributes.h Tue Jan 8 18:32:08 2013
@@ -315,7 +315,7 @@
AttributeSet removeAttr(LLVMContext &C, unsigned Idx, Attribute Attrs) const;
//===--------------------------------------------------------------------===//
- // Attribute List Accessors
+ // Attribute Set Accessors
//===--------------------------------------------------------------------===//
/// \brief The attributes for the specified index are returned.
@@ -365,7 +365,7 @@
}
//===--------------------------------------------------------------------===//
- // Attribute List Introspection
+ // Attribute Set Introspection
//===--------------------------------------------------------------------===//
/// \brief Return a raw pointer that uniquely identifies this attribute list.
Modified: llvm/trunk/lib/IR/AttributeImpl.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/AttributeImpl.h?rev=171923&r1=171922&r2=171923&view=diff
==============================================================================
--- llvm/trunk/lib/IR/AttributeImpl.h (original)
+++ llvm/trunk/lib/IR/AttributeImpl.h Tue Jan 8 18:32:08 2013
@@ -65,12 +65,7 @@
Profile(ID, Data, Vals);
}
static void Profile(FoldingSetNodeID &ID, Constant *Data,
- ArrayRef<Constant*> Vals) {
- ID.AddPointer(Data);
- for (ArrayRef<Constant*>::iterator I = Vals.begin(), E = Vals.end();
- I != E; ++I)
- ID.AddPointer(*I);
- }
+ ArrayRef<Constant*> Vals);
};
//===----------------------------------------------------------------------===//
Modified: llvm/trunk/lib/IR/Attributes.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/Attributes.cpp?rev=171923&r1=171922&r2=171923&view=diff
==============================================================================
--- llvm/trunk/lib/IR/Attributes.cpp (original)
+++ llvm/trunk/lib/IR/Attributes.cpp Tue Jan 8 18:32:08 2013
@@ -509,6 +509,14 @@
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
//===----------------------------------------------------------------------===//
More information about the llvm-commits
mailing list