[PATCH] D158837: [ConstraintElim] Store conditional facts as (Predicate, Op0, Op1).

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 29 06:58:20 PDT 2023


fhahn added inline comments.


================
Comment at: llvm/lib/Transforms/Scalar/ConstraintElimination.cpp:111
   bool Not;
+  bool HasCond = false;
 
----------------
nikic wrote:
> The flags here have become something of a mess. Can we represent these as an enum instead? Something like...
> 
> ```
> enum {
>   /// Fact implied by Inst, holds from the definition point of Inst.
>   InstFact,
>   /// Fact implied by Condition, holds from the start of the block.
>   CondFact,
>   /// Check at a specific use-site of an instruction.
>   UseCheck,
>   /// Check for all uses of an instruction.
>   InstCheck,
> }
> ```
> 
> ...assuming those are the possible cases, of which I'm not really sure.
Thanks, added an enum here: e6260ec49c5d


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D158837/new/

https://reviews.llvm.org/D158837



More information about the llvm-commits mailing list