[PATCH] D25005: [x86][inline-asm][llvm] accept 'v' constraint

Elena Demikhovsky via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 28 01:19:25 PDT 2016


delena added inline comments.

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:32380
@@ -32372,1 +32379,3 @@
       case MVT::i32:
+        if (VConstraint && Subtarget.hasAVX512())
+          return std::make_pair(0U, &X86::FR32XRegClass);
----------------
you can use FR32X if you have VLX. Otherwise take FR32. The same about other cases.

================
Comment at: lib/Target/X86/X86ISelLowering.cpp:32385
@@ -32375,1 +32384,3 @@
       case MVT::i64:
+         if (VConstraint && Subtarget.hasAVX512())
+           return std::make_pair(0U, &X86::FR64XRegClass);
----------------
line alignment

================
Comment at: test/CodeGen/X86/inline-asm-avx512-v-constraint.ll:1
@@ +1,2 @@
+; RUN: llc < %s -march x86-64 -mtriple x86_64-unknown-linux-gnu -mcpu skylake-avx512 | FileCheck %s
+
----------------
you also should check knl.
Community asks to avoid -mcpu flag and use -march instead. (I don't know why)


Repository:
  rL LLVM

https://reviews.llvm.org/D25005





More information about the llvm-commits mailing list