[PATCH] D154717: [LV] Check if ops can safely be truncated in computeMinimumValueSizes.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 7 10:19:26 PDT 2023


fhahn marked 2 inline comments as done.
fhahn added inline comments.


================
Comment at: llvm/lib/Analysis/VectorUtils.cpp:585
 
     // Non-instructions terminate a chain successfully.
     if (!isa<Instruction>(Val))
----------------
nikic wrote:
> We're effectively working around this.
> 
> Does make me wonder: If we make the Worklist work on Uses rather than Values, could we handle this directly in this loop?
I'm not sure if it would be worth checking the uses here, but it might be an option to check the operands earlier here


================
Comment at: llvm/lib/Analysis/VectorUtils.cpp:661
     for (Value *M : llvm::make_range(ECs.member_begin(I), ECs.member_end())) {
       if (!isa<Instruction>(M))
         continue;
----------------
nikic wrote:
> dyn_cast up here, use below?
updated, thanks!


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D154717



More information about the llvm-commits mailing list