From 08ef1b2bdb0d9d1a5ca6cceba551f31d9dd23e3c Mon Sep 17 00:00:00 2001 From: Scott Michel Date: Tue, 18 Mar 2008 16:55:06 +0000 Subject: [PATCH] Dial down gcc's warnings: don't use 0UL when 0U suffices (and when the variables and methods themselves only use unsigned.) llvm-svn: 48492 --- llvm/include/llvm/ADT/SparseBitVector.h | 2 +- llvm/lib/Analysis/IPA/Andersens.cpp | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/llvm/include/llvm/ADT/SparseBitVector.h b/llvm/include/llvm/ADT/SparseBitVector.h index 215149a5a699..4d37eae5df2f 100644 --- a/llvm/include/llvm/ADT/SparseBitVector.h +++ b/llvm/include/llvm/ADT/SparseBitVector.h @@ -70,7 +70,7 @@ private: BitWord Bits[BITWORDS_PER_ELEMENT]; // Needed for sentinels SparseBitVectorElement() { - ElementIndex = ~0UL; + ElementIndex = ~0U; memset(&Bits[0], 0, sizeof (BitWord) * BITWORDS_PER_ELEMENT); } diff --git a/llvm/lib/Analysis/IPA/Andersens.cpp b/llvm/lib/Analysis/IPA/Andersens.cpp index 8650fb1334c9..a66a6faf1c5d 100644 --- a/llvm/lib/Analysis/IPA/Andersens.cpp +++ b/llvm/lib/Analysis/IPA/Andersens.cpp @@ -171,10 +171,10 @@ namespace { // it's thing struct PairKeyInfo { static inline std::pair getEmptyKey() { - return std::make_pair(~0UL, ~0UL); + return std::make_pair(~0U, ~0U); } static inline std::pair getTombstoneKey() { - return std::make_pair(~0UL - 1, ~0UL - 1); + return std::make_pair(~0U - 1, ~0U - 1); } static unsigned getHashValue(const std::pair &P) { return P.first ^ P.second; @@ -187,10 +187,10 @@ namespace { struct ConstraintKeyInfo { static inline Constraint getEmptyKey() { - return Constraint(Constraint::Copy, ~0UL, ~0UL, ~0UL); + return Constraint(Constraint::Copy, ~0U, ~0U, ~0U); } static inline Constraint getTombstoneKey() { - return Constraint(Constraint::Copy, ~0UL - 1, ~0UL - 1, ~0UL - 1); + return Constraint(Constraint::Copy, ~0U - 1, ~0U - 1, ~0U - 1); } static unsigned getHashValue(const Constraint &C) { return C.Src ^ C.Dest ^ C.Type ^ C.Offset;