[PATCH] D130839: [DAG] FoldConstantArithmetic - add initial support for undef elements in bitcasted binop constant folding

Thorsten via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jul 31 06:48:01 PDT 2022


tschuett added inline comments.


================
Comment at: llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:5584
+        // Handle constant folding with UNDEF. TODO: Handle more cases.
+        auto FoldValueWithUndef = [](unsigned Opcode, const APInt &C1,
+                                     bool IsUndef1, const APInt &C2,
----------------
Do you need to hide this behind a lambda or could you pull it into a function because it is getting more powerful over time?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D130839



More information about the llvm-commits mailing list