[PATCH] D22726: [DAGCombine] Match shift amount by value rather than relying on common sub-expressions.

Sanjay Patel via llvm-commits llvm-commits at lists.llvm.org
Sun Aug 14 13:59:07 PDT 2016


spatel added a comment.

In https://reviews.llvm.org/D22726#514961, @bryant wrote:

> In https://reviews.llvm.org/D22726#513819, @spatel wrote:
>
> > The problem summary notes that this fold is missing from InstCombine. Would we sidestep the later questions (and possibly target-specific problems) by doing the transform in IR?
>
>
> I'm totally open to doing this in InstCombine, hence making the note in the first place.


Sure. Let me rephrase the question: are you seeing any cases where the opportunity to perform the optimization only emerges in the DAG? If no, then let's start a new patch that does the transform in InstCombine. The earlier IR optimization always beats a DAG combine in reach and can enable other folds to trigger.


Repository:
  rL LLVM

https://reviews.llvm.org/D22726





More information about the llvm-commits mailing list