[PATCH] D132329: [X86][RFC] Using `__bf16` for AVX512_BF16 intrinsics

Simon Pilgrim via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Sep 21 03:47:32 PDT 2022


RKSimon added inline comments.


================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:2185
+    addRegisterClass(MVT::v32bf16, &X86::VR512RegClass);
+    setOperationAction(ISD::BUILD_VECTOR, MVT::bf16, Custom);
+    setOperationAction(ISD::BUILD_VECTOR, MVT::v8bf16, Custom);
----------------
pengfei wrote:
> RKSimon wrote:
> > Isn't MVT::bf16 scalar? 
> Yes, when legalize the source operand, the legalizer gets action as the type action, i.e., `TypeSoftPromoteHalf`. However, we don't provide methods to handle any vector actions in soft promote. So we need to set it `Custom` here to do the customization.
OK - please can you add a short comment explaining that


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D132329/new/

https://reviews.llvm.org/D132329



More information about the cfe-commits mailing list