craig.topper added inline comments.

================
Comment at: clang/lib/CodeGen/CGCall.cpp:3135
           STy->getNumElements() > 1) {
-        uint64_t SrcSize = CGM.getDataLayout().getTypeAllocSize(STy);
-        llvm::Type *DstTy = Ptr.getElementType();
-        uint64_t DstSize = CGM.getDataLayout().getTypeAllocSize(DstTy);
+        if (CGM.getDataLayout().getTypeAllocSize(STy).isScalable()) {
+          assert(STy->containsHomogeneousScalableVectorTypes() &&
----------------
Can cache GM.getDataLayout().getTypeAllocSize(STy) in a variable? We call it 
here and inside both the if and the else body.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D146873

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to