[PATCH] D86347: [SimplifyCFG] Two entry phi select costs
Sam Parker via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 21 07:14:47 PDT 2020
samparker added inline comments.
================
Comment at: llvm/lib/Transforms/Utils/SimplifyCFG.cpp:2011
+ if (OrigV != ThenV)
+ BudgetRemaining -=
+ TTI.getCmpSelInstrCost(Instruction::Select, PN.getType(), nullptr,
----------------
lebedev.ri wrote:
> samparker wrote:
> > lebedev.ri wrote:
> > > I'm not sure this does what you think it does..
> > Do you think this is wrong? What do you think it should be doing?
> Well, the function takes `BudgetRemaining` by value,
> so this doesn't actually change the `BudgetRemaining` in the caller function.
Right, this patch will need to be changed to work with D86346, but as a standalone patch it does what it should.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D86347/new/
https://reviews.llvm.org/D86347
More information about the llvm-commits
mailing list