summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-08-22 05:08:25 +0000
committerChris Lattner <sabre@nondot.org>2008-08-22 05:08:25 +0000
commit5fc8ab6d187aefbf1d2cbd36e191e675b14db8f6 (patch)
tree59bbe857f9f2d99c73b282c0599e606ce4a6da41 /llvm/lib
parent41e0881b34bec00cfc4d6e62783716d51db4624f (diff)
downloadbcm5719-llvm-5fc8ab6d187aefbf1d2cbd36e191e675b14db8f6.tar.gz
bcm5719-llvm-5fc8ab6d187aefbf1d2cbd36e191e675b14db8f6.zip
consolidate DenseMapInfo implementations, and add one for std::pair.
Patch contributed by m-s. llvm-svn: 55167
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/CodeGen/RegAllocLocal.cpp12
-rw-r--r--llvm/lib/Transforms/Scalar/GVN.cpp12
2 files changed, 0 insertions, 24 deletions
diff --git a/llvm/lib/CodeGen/RegAllocLocal.cpp b/llvm/lib/CodeGen/RegAllocLocal.cpp
index a660e00aa8b..5946e749022 100644
--- a/llvm/lib/CodeGen/RegAllocLocal.cpp
+++ b/llvm/lib/CodeGen/RegAllocLocal.cpp
@@ -561,18 +561,6 @@ static bool precedes(MachineBasicBlock::iterator A,
return false;
}
-namespace llvm {
- template<> struct DenseMapInfo<uint32_t> {
- static inline uint32_t getEmptyKey() { return ~0; }
- static inline uint32_t getTombstoneKey() { return ~0 - 1; }
- static unsigned getHashValue(const uint32_t& Val) { return Val * 37; }
- static bool isPod() { return true; }
- static bool isEqual(const uint32_t& LHS, const uint32_t& RHS) {
- return LHS == RHS;
- }
- };
-}
-
/// ComputeLocalLiveness - Computes liveness of registers within a basic
/// block, setting the killed/dead flags as appropriate.
void RALocal::ComputeLocalLiveness(MachineBasicBlock& MBB) {
diff --git a/llvm/lib/Transforms/Scalar/GVN.cpp b/llvm/lib/Transforms/Scalar/GVN.cpp
index a8b4905a4cf..272ad1b99b9 100644
--- a/llvm/lib/Transforms/Scalar/GVN.cpp
+++ b/llvm/lib/Transforms/Scalar/GVN.cpp
@@ -682,18 +682,6 @@ void ValueTable::erase(Value* V) {
// GVN Pass
//===----------------------------------------------------------------------===//
-namespace llvm {
- template<> struct DenseMapInfo<uint32_t> {
- static inline uint32_t getEmptyKey() { return ~0; }
- static inline uint32_t getTombstoneKey() { return ~0 - 1; }
- static unsigned getHashValue(const uint32_t& Val) { return Val * 37; }
- static bool isPod() { return true; }
- static bool isEqual(const uint32_t& LHS, const uint32_t& RHS) {
- return LHS == RHS;
- }
- };
-}
-
namespace {
struct VISIBILITY_HIDDEN ValueNumberScope {
ValueNumberScope* parent;
OpenPOWER on IntegriCloud