OSDN Git Service

[X86][BMI1] X86DAGToDAGISel: select BEXTR from x & (-1 >> (32 - y)) pattern
authorRoman Lebedev <lebedev.ri@gmail.com>
Tue, 30 Oct 2018 11:12:34 +0000 (11:12 +0000)
committerRoman Lebedev <lebedev.ri@gmail.com>
Tue, 30 Oct 2018 11:12:34 +0000 (11:12 +0000)
commitae66d6c10922f7562dffabc9926901e4943b331a
tree918f3df2eb7617ce41554d14f7712164a1b7d2e2
parentf276cd655988dea8dd0a66597afdfe850ec07515
[X86][BMI1] X86DAGToDAGISel: select BEXTR from x &  (-1 >> (32 - y)) pattern

Summary:
The final pattern.
There is no test changes:
* We are looking for the pattern with one-use of it's mask,
* If the mask is one-use, D48768 will unfold it into pattern d.
* Thus, the tests have extra-use on the mask.
* Thus, only the BMI2 BZHI can be tested, and it already worked.
* So there is no BMI1 test coverage, we just assume it works since it uses the same codepath.

Reviewers: craig.topper, RKSimon

Reviewed By: RKSimon

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D53575

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@345584 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86ISelDAGToDAG.cpp
lib/Target/X86/X86InstrInfo.td