forked from OSchip/llvm-project
[AArch64][SVE] Only support sizeless bfloat types if supported by subtarget
Reviewers: sdesmalen, efriedma, kmclaughlin, fpetrogalli Reviewed By: sdesmalen, fpetrogalli Differential Revision: https://reviews.llvm.org/D82494
This commit is contained in:
parent
cb56fa2196
commit
4319c48fc7
|
@ -177,13 +177,16 @@ AArch64TargetLowering::AArch64TargetLowering(const TargetMachine &TM,
|
||||||
addRegisterClass(MVT::nxv2f16, &AArch64::ZPRRegClass);
|
addRegisterClass(MVT::nxv2f16, &AArch64::ZPRRegClass);
|
||||||
addRegisterClass(MVT::nxv4f16, &AArch64::ZPRRegClass);
|
addRegisterClass(MVT::nxv4f16, &AArch64::ZPRRegClass);
|
||||||
addRegisterClass(MVT::nxv8f16, &AArch64::ZPRRegClass);
|
addRegisterClass(MVT::nxv8f16, &AArch64::ZPRRegClass);
|
||||||
addRegisterClass(MVT::nxv2bf16, &AArch64::ZPRRegClass);
|
|
||||||
addRegisterClass(MVT::nxv4bf16, &AArch64::ZPRRegClass);
|
|
||||||
addRegisterClass(MVT::nxv8bf16, &AArch64::ZPRRegClass);
|
|
||||||
addRegisterClass(MVT::nxv2f32, &AArch64::ZPRRegClass);
|
addRegisterClass(MVT::nxv2f32, &AArch64::ZPRRegClass);
|
||||||
addRegisterClass(MVT::nxv4f32, &AArch64::ZPRRegClass);
|
addRegisterClass(MVT::nxv4f32, &AArch64::ZPRRegClass);
|
||||||
addRegisterClass(MVT::nxv2f64, &AArch64::ZPRRegClass);
|
addRegisterClass(MVT::nxv2f64, &AArch64::ZPRRegClass);
|
||||||
|
|
||||||
|
if (Subtarget->hasBF16()) {
|
||||||
|
addRegisterClass(MVT::nxv2bf16, &AArch64::ZPRRegClass);
|
||||||
|
addRegisterClass(MVT::nxv4bf16, &AArch64::ZPRRegClass);
|
||||||
|
addRegisterClass(MVT::nxv8bf16, &AArch64::ZPRRegClass);
|
||||||
|
}
|
||||||
|
|
||||||
if (useSVEForFixedLengthVectors()) {
|
if (useSVEForFixedLengthVectors()) {
|
||||||
for (MVT VT : MVT::integer_fixedlen_vector_valuetypes())
|
for (MVT VT : MVT::integer_fixedlen_vector_valuetypes())
|
||||||
if (useSVEForFixedLengthVectorVT(VT))
|
if (useSVEForFixedLengthVectorVT(VT))
|
||||||
|
|
Loading…
Reference in New Issue