[PATCH] D140750: [TargetLowering] Teach BuildUDIV to take advantage of leading zeros in the dividend.
Roman Lebedev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 29 05:31:45 PST 2022
lebedev.ri added a comment.
Can you update the exhaustive test too so we know this is actually correct?
================
Comment at: llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp:6025
+ unsigned LeadingZeros = 0;
+ if (!VT.isVector() && isa<ConstantSDNode>(N1)) {
+ LeadingZeros = DAG.computeKnownBits(N0).countMinLeadingZeros();
----------------
Why not vectors?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D140750/new/
https://reviews.llvm.org/D140750
More information about the llvm-commits
mailing list