[llvm] a9b137f - [SVE] Remove calls to getBitWidth from PowerPC
Christopher Tetreault via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 20 14:18:52 PDT 2020
Author: Christopher Tetreault
Date: 2020-04-20T14:18:37-07:00
New Revision: a9b137f9ffba8cb25dfd7dd1fb613e8aac121b37
URL: https://github.com/llvm/llvm-project/commit/a9b137f9ffba8cb25dfd7dd1fb613e8aac121b37
DIFF: https://github.com/llvm/llvm-project/commit/a9b137f9ffba8cb25dfd7dd1fb613e8aac121b37.diff
LOG: [SVE] Remove calls to getBitWidth from PowerPC
Reviewers: efriedma, sdesmalen, hfinkel, david-arm, fpetrogalli
Reviewed By: efriedma, fpetrogalli
Subscribers: wuzish, nemanjai, tschuett, hiraditya, kbarton, rkruppe, psnobl, shchenz, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D77900
Added:
Modified:
llvm/lib/Target/PowerPC/PPCISelLowering.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
index dd24c05022fa..c8de65d25afd 100644
--- a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
+++ b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
@@ -1333,9 +1333,11 @@ static void getMaxByValAlign(Type *Ty, unsigned &MaxAlign,
if (MaxAlign == MaxMaxAlign)
return;
if (VectorType *VTy = dyn_cast<VectorType>(Ty)) {
- if (MaxMaxAlign >= 32 && VTy->getBitWidth() >= 256)
+ if (MaxMaxAlign >= 32 &&
+ VTy->getPrimitiveSizeInBits().getFixedSize() >= 256)
MaxAlign = 32;
- else if (VTy->getBitWidth() >= 128 && MaxAlign < 16)
+ else if (VTy->getPrimitiveSizeInBits().getFixedSize() >= 128 &&
+ MaxAlign < 16)
MaxAlign = 16;
} else if (ArrayType *ATy = dyn_cast<ArrayType>(Ty)) {
unsigned EltAlign = 0;
More information about the llvm-commits
mailing list