[PATCH] D44367: [InstCombine] peek through FP casts for sign-bit compares (PR36682)

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 11 16:08:04 PDT 2018


spatel added a comment.

In https://reviews.llvm.org/D44367#1034254, @spatel wrote:

> In https://reviews.llvm.org/D44367#1034253, @lebedev.ri wrote:
>
> > Ok, i have limited the test generator to just the `sitofp`, `slt 0` / `sle -1` / `sgt -1` / `sge 0`, added `undef` in the middle of vector variant.
> >  Good news is that all the scalar cases are indeed handled.
> >  Bad news is that half of the vector cases is not handled.
>
>
> Ah, you're detecting a missing undef pattern match for m_Zero(). Nobody made that change to that matcher yet, unlike m_AllOnes().


To make that clear - if you make the vector constants 'zeroinitializer' or make all elements explicitly '0' rather than including undef, I expect them to be folded.


https://reviews.llvm.org/D44367





More information about the llvm-commits mailing list