1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 03:33:20 +01:00

Fix a warning about comparison between signed and unsigned,

being consistent with the rest of the APInt implementation.

llvm-svn: 47138
This commit is contained in:
Dan Gohman 2008-02-14 22:38:45 +00:00
parent b8bf200b77
commit 9ca30afc39

View File

@ -818,7 +818,7 @@ uint32_t APInt::countTrailingOnes() const {
return std::min(uint32_t(CountTrailingOnes_64(VAL)), BitWidth);
uint32_t Count = 0;
uint32_t i = 0;
for (; i < getNumWords() && pVal[i] == -1; ++i)
for (; i < getNumWords() && pVal[i] == -1ULL; ++i)
Count += APINT_BITS_PER_WORD;
if (i < getNumWords())
Count += CountTrailingOnes_64(pVal[i]);