[PATCH] D99682: [SelectionDAG] Teach SelectionDAG::FoldConstantArithmetic to handle SPLAT_VECTOR

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 6 10:00:39 PDT 2021


craig.topper added inline comments.


================
Comment at: llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:5179
+    // Build a big vector out of the scalar elements we generated.
+    // TODO: If the inputs were fixed length SPLAT_VECTORs, should this return
+    // a SPLAT_VECTOR?
----------------
david-arm wrote:
> nit: Perhaps this should be something like:
> 
>   If one of the inputs is a fixed length SPLAT_VECTOR ...
> 
> since at least one input is BUILD_VECTOR?
I think I just forgot to delete that TODO when I refactored.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D99682



More information about the llvm-commits mailing list