[llvm-commits] [126244] Use ConstantInt:: getAllOnesValue to get hold of -1 in CEIL_DIV_EXPR.
clattner at apple.com
clattner at apple.com
Tue Apr 17 09:28:46 PDT 2007
Revision: 126244
Author: clattner
Date: 2007-04-17 09:28:45 -0700 (Tue, 17 Apr 2007)
Log Message:
-----------
Use ConstantInt::getAllOnesValue to get hold of -1 in CEIL_DIV_EXPR.
Patch by Duncan Sands
Modified Paths:
--------------
apple-local/branches/llvm/gcc/llvm-convert.cpp
Modified: apple-local/branches/llvm/gcc/llvm-convert.cpp
===================================================================
--- apple-local/branches/llvm/gcc/llvm-convert.cpp 2007-04-17 07:31:45 UTC (rev 126243)
+++ apple-local/branches/llvm/gcc/llvm-convert.cpp 2007-04-17 16:28:45 UTC (rev 126244)
@@ -3244,7 +3244,7 @@
const Type *Ty = ConvertType(TREE_TYPE(exp));
Constant *Zero = ConstantInt::get(Ty, 0);
Constant *One = ConstantInt::get(Ty, 1);
- Constant *MinusOne = ConstantInt::get(Ty, -1U);
+ Constant *MinusOne = ConstantInt::getAllOnesValue(Ty);
Value *LHS = Emit(TREE_OPERAND(exp, 0), 0);
Value *RHS = Emit(TREE_OPERAND(exp, 1), 0);
More information about the llvm-commits
mailing list