From f3f6aaa2c3490d760feee6847f7c2292aed6b2a5 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. llvm-svn: 74698 --- llvm/lib/Transforms/Scalar/JumpThreading.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/lib/Transforms/Scalar/JumpThreading.cpp b/llvm/lib/Transforms/Scalar/JumpThreading.cpp index c3aee01e6446..611d24b13364 100644 --- a/llvm/lib/Transforms/Scalar/JumpThreading.cpp +++ b/llvm/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; } }