[PATCH] D43275: [AMDGPU]Increased vector length for global/constant loads.

Farhana Aleen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 14 08:30:02 PST 2018


FarhanaAleen added a comment.

Does amdgpu only support gfx6 (si) and above? I thought northern islands was supported by the r600 backend.

>> AMDGPU contains the general target information for all gpus and specific target implementation is supported by the specific backend; such as r600 and SI backends.



================
Comment at: lib/Target/AMDGPU/AMDGPUTargetTransformInfo.h:121
   unsigned getMinVectorRegisterBitWidth() const;
+  unsigned getLoadVectorFactor(unsigned VF, unsigned LoadSize,
+                               unsigned ChainSizeInBytes,
----------------
t-tye wrote:
> I did not see where in this patch these new functions are being used. 
These are not new functions; the default definitions can be found in  TargetTransformInfoImpl.h. loadStoreVectorizer was using the default implementation of these functions for AMDGPU since there were no implementation of these functions for AMDGPU.
I have copy-pasted the default definitions here for convenience. 

unsigned getLoadVectorFactor(unsigned VF, unsigned LoadSize,
                               unsigned ChainSizeInBytes,
                               VectorType *VecTy) const {
    return VF;
  }

  unsigned getStoreVectorFactor(unsigned VF, unsigned StoreSize,
                                unsigned ChainSizeInBytes,
                                VectorType *VecTy) const {
    return VF;
  }




https://reviews.llvm.org/D43275





More information about the llvm-commits mailing list