summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-01-12 18:23:49 +0000
committerChris Lattner <sabre@nondot.org>2007-01-12 18:23:49 +0000
commit3b641bfba575aeef6d236af38405c38f5e220893 (patch)
tree8b88011eaeb90058e25c8f71914747ad23dc6e88 /llvm
parentc5e5b2757376c745fc69e3682a6b85fe364d4069 (diff)
downloadbcm5719-llvm-3b641bfba575aeef6d236af38405c38f5e220893.tar.gz
bcm5719-llvm-3b641bfba575aeef6d236af38405c38f5e220893.zip
remove unneeded special cases
llvm-svn: 33127
Diffstat (limited to 'llvm')
-rw-r--r--llvm/lib/Analysis/ConstantRange.cpp7
1 files changed, 0 insertions, 7 deletions
diff --git a/llvm/lib/Analysis/ConstantRange.cpp b/llvm/lib/Analysis/ConstantRange.cpp
index 7a344201dd3..08edf6538b2 100644
--- a/llvm/lib/Analysis/ConstantRange.cpp
+++ b/llvm/lib/Analysis/ConstantRange.cpp
@@ -31,8 +31,6 @@
using namespace llvm;
static ConstantInt *getMaxValue(const Type *Ty, bool isSigned = false) {
- if (Ty == Type::Int1Ty)
- return ConstantInt::getTrue();
if (Ty->isInteger()) {
if (isSigned) {
// Calculate 011111111111111...
@@ -48,8 +46,6 @@ static ConstantInt *getMaxValue(const Type *Ty, bool isSigned = false) {
// Static constructor to create the minimum constant for an integral type...
static ConstantInt *getMinValue(const Type *Ty, bool isSigned = false) {
- if (Ty == Type::Int1Ty)
- return ConstantInt::getFalse();
if (Ty->isInteger()) {
if (isSigned) {
// Calculate 1111111111000000000000
@@ -63,9 +59,6 @@ static ConstantInt *getMinValue(const Type *Ty, bool isSigned = false) {
return 0;
}
static ConstantInt *Next(ConstantInt *CI) {
- if (CI->getType() == Type::Int1Ty)
- return ConstantInt::get(Type::Int1Ty, !CI->getZExtValue());
-
Constant *Result = ConstantExpr::getAdd(CI,
ConstantInt::get(CI->getType(), 1));
return cast<ConstantInt>(Result);
OpenPOWER on IntegriCloud