[PATCH] D82582: [SVE] Remove calls to VectorType::getNumElements from clang
Christopher Tetreault via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 25 11:33:47 PDT 2020
ctetreau marked 8 inline comments as done.
ctetreau added inline comments.
================
Comment at: clang/lib/CodeGen/CGExpr.cpp:1765
}
auto *VectorTy = dyn_cast<llvm::VectorType>(
cast<llvm::PointerType>(Addr.getPointer()->getType())->getElementType());
----------------
c-rhodes wrote:
> cast here
that would be a behavior change because of the dyn_cast.
================
Comment at: clang/lib/CodeGen/CGExpr.cpp:1799
llvm::Type *SrcTy = Value->getType();
auto *VecTy = dyn_cast<llvm::VectorType>(SrcTy);
// Handle vec3 special.
----------------
c-rhodes wrote:
> cast here
that would be a behavior change because of the dyn_cast
================
Comment at: clang/lib/CodeGen/CGExpr.cpp:2214
if (const VectorType *VTy = Dst.getType()->getAs<VectorType>()) {
unsigned NumSrcElts = VTy->getNumElements();
unsigned NumDstElts =
----------------
c-rhodes wrote:
> missed one here
this VTy is a clang::VectorType
================
Comment at: clang/lib/CodeGen/SwiftCallingConv.cpp:321
// If we have a vector type, split it.
if (auto vecTy = dyn_cast_or_null<llvm::VectorType>(type)) {
auto eltTy = vecTy->getElementType();
----------------
c-rhodes wrote:
> cast here
this would be a behavior change due to dyn_cast
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D82582/new/
https://reviews.llvm.org/D82582
More information about the cfe-commits
mailing list