The 64-bit constructor for ConstantInt changes from int64_t to uint64_t.

This caused a warning for construction with -1. Avoid the warning by using
-1ULL instead.

llvm-svn: 34796
This commit is contained in:
Reid Spencer 2007-03-01 19:33:52 +00:00
parent fad3f247e4
commit 24f1a0e78f
1 changed files with 1 additions and 1 deletions

View File

@ -5063,7 +5063,7 @@ Instruction *InstCombiner::visitICmpInst(ICmpInst &I) {
ConstantInt *CUI = cast<ConstantInt>(CI);
if (CUI->getZExtValue() == 1ULL << (SrcTySize-1))
return new ICmpInst(ICmpInst::ICMP_SGT, CastOp,
ConstantInt::get(SrcTy, -1));
ConstantInt::get(SrcTy, -1ULL));
break;
}
case ICmpInst::ICMP_UGT: { // X u> 127 => X s< 0