[llvm] [ValueTracking] Add support for `vector_reduce_{s, u}{min, max}` in `isKnownNonZero`/`computeKnownBits`. (PR #88169)
via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 9 21:29:59 PDT 2024
goldsteinn wrote:
> I think some basic support here could be reasonable, but this implementation looks too precise. In particular, I think the approach of doing a per-element evaluation of the vector is unprecedented -- we generally only look at all (demanded) elements as a unit.
>
> So the implementation I'd expect would be more something along the lines of taking the known bits of the input vector and using those as the result known bits as well. (For min/max reductions that is, not quite that simple for some of the other ones.)
for `min`/`max`/`or` its pretty easy to do a reasonable job w.o per-ele, but that kind of prohibits things like `xor`/`add`/etc... Are you opposed to those being added in general?
https://github.com/llvm/llvm-project/pull/88169
More information about the llvm-commits
mailing list