mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-21 19:48:19 +00:00
CVP. Turn marking adds as no wrap (introduced by r278107) off by default
It causes a regression on our internal benchmark. Introduce cvp-dont-process flag and set it off by default while investigating the regression. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@279082 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
2afbd4c045
commit
2e26f159da
@ -40,6 +40,8 @@ STATISTIC(NumDeadCases, "Number of switch cases removed");
|
||||
STATISTIC(NumSDivs, "Number of sdiv converted to udiv");
|
||||
STATISTIC(NumSRems, "Number of srem converted to urem");
|
||||
|
||||
static cl::opt<bool> DontProcessAdds("cvp-dont-process-adds", cl::init(true));
|
||||
|
||||
namespace {
|
||||
class CorrelatedValuePropagation : public FunctionPass {
|
||||
public:
|
||||
@ -385,6 +387,9 @@ static bool processSDiv(BinaryOperator *SDI, LazyValueInfo *LVI) {
|
||||
static bool processAdd(BinaryOperator *AddOp, LazyValueInfo *LVI) {
|
||||
typedef OverflowingBinaryOperator OBO;
|
||||
|
||||
if (DontProcessAdds)
|
||||
return false;
|
||||
|
||||
if (AddOp->getType()->isVectorTy() || hasLocalDefs(AddOp))
|
||||
return false;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
; RUN: opt < %s -correlated-propagation -S | FileCheck %s
|
||||
; RUN: opt < %s -correlated-propagation -cvp-dont-process-adds=false -S | FileCheck %s
|
||||
|
||||
; CHECK-LABEL: @test0(
|
||||
define void @test0(i32 %a) {
|
||||
|
Loading…
Reference in New Issue
Block a user