From 62c762f329cb16783f19b075bb2fefe35b5d5879 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Thu, 2 Jul 2009 15:39:39 +0000 Subject: [PATCH] fix inverted logic pointed out by John McCall, noticed by inspection. This was considering vector intrinsics to have cost 2, but non-vector intrinsics to have cost 1, which is backward. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74698 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/Scalar/JumpThreading.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Transforms/Scalar/JumpThreading.cpp b/lib/Transforms/Scalar/JumpThreading.cpp index c3aee01e644..611d24b1336 100644 --- a/lib/Transforms/Scalar/JumpThreading.cpp +++ b/lib/Transforms/Scalar/JumpThreading.cpp @@ -207,7 +207,7 @@ static unsigned getJumpThreadDuplicationCost(const BasicBlock *BB) { if (const CallInst *CI = dyn_cast(I)) { if (!isa(CI)) Size += 3; - else if (isa(CI->getType())) + else if (!isa(CI->getType())) Size += 1; } }