[JumpThreading] Fix opcode bonus in getJumpThreadDuplicationCost()
authorGeoff Berry <gberry@codeaurora.org>
Tue, 29 Dec 2015 18:10:16 +0000 (18:10 +0000)
committerGeoff Berry <gberry@codeaurora.org>
Tue, 29 Dec 2015 18:10:16 +0000 (18:10 +0000)
commit7a394796742e8db24f1365f00d6f7322c34353f9
tree8a9dc562c0a1803ab41d1feb880d5622d0986843
parentc32ece6aeeebc96102353a655e46c92f620cbaa3
[JumpThreading] Fix opcode bonus in getJumpThreadDuplicationCost()

The code that was meant to adjust the duplication cost based on the
terminator opcode was not being executed in cases where the initial
threshold was hit inside the loop.

Subscribers: mcrosier, llvm-commits

Differential Revision: http://reviews.llvm.org/D15536

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@256568 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/JumpThreading.cpp
test/Transforms/JumpThreading/select.ll