[PATCH] D74724: [AArch64][SVE] CodeGen of ACLE Builtin Types
Eli Friedman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Feb 17 11:44:16 PST 2020
efriedma added inline comments.
================
Comment at: clang/lib/CodeGen/CodeGenTypes.cpp:559
#include "clang/Basic/AArch64SVEACLETypes.def"
- {
- unsigned DiagID = CGM.getDiags().getCustomDiagID(
- DiagnosticsEngine::Error,
- "cannot yet generate code for SVE type '%0'");
- auto *BT = cast<BuiltinType>(Ty);
- auto Name = BT->getName(CGM.getContext().getPrintingPolicy());
- CGM.getDiags().Report(DiagID) << Name;
- // Return something safe.
- ResultType = llvm::IntegerType::get(getLLVMContext(), 32);
- break;
+ ResultType = getSVEType(getContext(), getLLVMContext(),
+ cast<BuiltinType>(Ty)->getKind());
----------------
Is there a reason to make getSVEType a separate function, as opposed to just writing out the cases inline?
Also, we can probably get rid of the "cannot yet generate code for SVE type" error?
================
Comment at: llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp:230
+ uint64_t ElementSize =
+ DL->getTypeAllocSize(AI.getAllocatedType()).getKnownMinSize();
uint64_t Size =
----------------
Please submit this separately.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D74724/new/
https://reviews.llvm.org/D74724
More information about the cfe-commits
mailing list