[PATCH] D149916: [VP][SelectionDAG][RISCV] Add get_vector_length intrinsics and generic SelectionDAG support.
Philip Reames via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu May 25 12:30:34 PDT 2023
reames added inline comments.
================
Comment at: llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:7326
+
+ SDValue MaxEVL;
+ if (IsScalable)
----------------
I believe this is just computing the number of elements in the ElementCount constructed from VF and the scaleable bit.
On the IR level, we have CreateElementCount on IRBuilder. We probably need something analogous on DAG. It looks like we've got a couple examples already, so it'd be good to pull that out and rebase.
One generic optimization we should probably add (in a separate patch), is to fold get_active_vector_length to TC when TC can be proven less than EC.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D149916/new/
https://reviews.llvm.org/D149916
More information about the llvm-commits
mailing list