]> granicus.if.org Git - llvm/commitdiff
[X86] Add BLSR and BLSMSK to isUseDefConvertible.
authorCraig Topper <craig.topper@intel.com>
Wed, 10 Jul 2019 22:14:39 +0000 (22:14 +0000)
committerCraig Topper <craig.topper@intel.com>
Wed, 10 Jul 2019 22:14:39 +0000 (22:14 +0000)
Unfortunately subo formation in CGP prevents obvious ways of
testing this.

But we already have BLSI in here and the flag behavior is
well understood.

Might become more useful if we improve PR42571.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@365702 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/X86/X86InstrInfo.cpp

index 6ecee41fd037c2105ef3aabb626e97e6c3f26f85..4a5f773553089f65db44aa920493305fdf1f0e06 100644 (file)
@@ -3396,7 +3396,12 @@ static X86::CondCode isUseDefConvertible(const MachineInstr &MI) {
   case X86::BLSI32rr:
   case X86::BLSI64rr:
     return X86::COND_AE;
-  // TODO: BLSR, BLSMSK, and TBM instructions.
+  case X86::BLSR32rr:
+  case X86::BLSR64rr:
+  case X86::BLSMSK32rr:
+  case X86::BLSMSK64rr:
+    return X86::COND_B;
+  // TODO: TBM instructions.
   }
 }