From a2913eea9d7530f8cad652b984cb642ee12c0d6d Mon Sep 17 00:00:00 2001 From: Reid Spencer Date: Thu, 21 Dec 2006 07:15:54 +0000 Subject: [PATCH] Get rid of a useless if statement whose then and else blocks were identical. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32729 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/IPO/SimplifyLibCalls.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/Transforms/IPO/SimplifyLibCalls.cpp b/lib/Transforms/IPO/SimplifyLibCalls.cpp index bbe020ce1e9..7cc1a5bccb5 100644 --- a/lib/Transforms/IPO/SimplifyLibCalls.cpp +++ b/lib/Transforms/IPO/SimplifyLibCalls.cpp @@ -920,10 +920,7 @@ struct StrLenOptimization : public LibCallOptimization { // strlen("xyz") -> 3 (for example) const Type *Ty = SLC.getTargetData()->getIntPtrType(); - if (Ty->isSigned()) - ci->replaceAllUsesWith(ConstantInt::get(Ty, len)); - else - ci->replaceAllUsesWith(ConstantInt::get(Ty, len)); + ci->replaceAllUsesWith(ConstantInt::get(Ty, len)); ci->eraseFromParent(); return true;