[PATCH] D103951: [NFC][Scheduler] Refactor tryCandidate to return boolean
Jay Foad via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 22 01:39:22 PDT 2021
foad added inline comments.
================
Comment at: llvm/lib/CodeGen/MachineScheduler.cpp:3191
// Bias PhysReg Defs and copies to their uses and defined respectively.
if (tryGreater(biasPhysReg(TryCand.SU, TryCand.AtTop),
biasPhysReg(Cand.SU, Cand.AtTop), TryCand, Cand, PhysReg))
----------------
Surely all of these "try" functions should consistently only return true when they set Reason to something useful? So all these clauses should just be:
```
if (trySomething(...))
return true;
```
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D103951/new/
https://reviews.llvm.org/D103951
More information about the llvm-commits
mailing list