[llvm] 21dadd7 - [DAGCombiner] avoid unnecessary indirection from SDNode/SDValue; NFCI

Hans Wennborg via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 4 03:32:19 PDT 2020


On Thu, Jun 4, 2020 at 12:24 PM Tim Northover via llvm-commits
<llvm-commits at lists.llvm.org> wrote:
>
> Hi Sanjay,
>
> On Fri, 29 May 2020 at 14:37, Sanjay Patel via llvm-commits
> <llvm-commits at lists.llvm.org> wrote:
> > -    Replace0 &= !N0->hasOneUse();
> > -    Replace1 &= (N0 != N1) && !N1->hasOneUse();
> > +    Replace0 &= !N0.hasOneUse();
> > +    Replace1 &= (N0 != N1) && !N1.hasOneUse();
>
> I believe this change caused a regression because other values
> produced by the SDNode may have users too. This affected sqlite
> originally, but see the attached smaller reproducer. Because we don't
> notice the user of the load's chain it gets orphaned and emitted after
> the call it should precede.
>
> I've not reverted it outright, but kind of think it might be a good
> idea; it wasn't immediately obvious to me that this is the only site
> that cared about other results.

See also https://bugs.llvm.org/show_bug.cgi?id=46194

I think reverting for now would make sense.


More information about the llvm-commits mailing list