[llvm] [AMDGPU] Enable vectorization of i8 values. (PR #134934)

Gheorghe-Teodor Bercea via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 22 15:18:08 PDT 2025


================
@@ -344,9 +344,10 @@ unsigned GCNTTIImpl::getMinVectorRegisterBitWidth() const {
 unsigned GCNTTIImpl::getMaximumVF(unsigned ElemWidth, unsigned Opcode) const {
   if (Opcode == Instruction::Load || Opcode == Instruction::Store)
     return 32 * 4 / ElemWidth;
-  return (ElemWidth == 16 && ST->has16BitInsts()) ? 2
-       : (ElemWidth == 32 && ST->hasPackedFP32Ops()) ? 2
-       : 1;
+  return ElemWidth == 8                                ? 4
----------------
doru1004 wrote:

This is only called in 2 places so I added an extra test to cover that.

https://github.com/llvm/llvm-project/pull/134934


More information about the llvm-commits mailing list