[SVE] Remove calls to getBitWidth from mips
authorChristopher Tetreault <ctetreau@quicinc.com>
Mon, 20 Apr 2020 20:58:02 +0000 (13:58 -0700)
committerChristopher Tetreault <ctetreau@quicinc.com>
Mon, 20 Apr 2020 21:09:06 +0000 (14:09 -0700)
Reviewers: efriedma, ahatanak, sdesmalen, c-rhodes, david-arm

Reviewed By: efriedma

Subscribers: dexonsmith, sdardis, arichardson, tschuett, hiraditya, jrtc27, atanasyan, rkruppe, psnobl, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D77906

llvm/lib/Target/Mips/MipsISelLowering.cpp

index 7a89ac2..d305c1c 100644 (file)
@@ -3948,7 +3948,7 @@ MipsTargetLowering::getSingleConstraintMatchWeight(
     break;
   case 'f': // FPU or MSA register
     if (Subtarget.hasMSA() && type->isVectorTy() &&
-        cast<VectorType>(type)->getBitWidth() == 128)
+        type->getPrimitiveSizeInBits().getFixedSize() == 128)
       weight = CW_Register;
     else if (type->isFloatTy())
       weight = CW_Register;