From: eopXD Date: Sat, 7 Jan 2023 09:04:26 +0000 (-0800) Subject: [4/15][Clang][RISCV][NFC] Remove unnecessary logic under RVVIntrinsic::computeBuiltin... X-Git-Tag: upstream/17.0.6~19857 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f8ec44b2a0e29fa6edf3cc3b48c42e862a112039;p=platform%2Fupstream%2Fllvm.git [4/15][Clang][RISCV][NFC] Remove unnecessary logic under RVVIntrinsic::computeBuiltinTypes `PolicyAttrs::IsUnspecified` is modified in `RVV::Intrinsic::computeBuiltInTypes` and used under `RVVIntrinsic::updateNamesAndPolicy`. Suprisingly the modification in `RVV::Intrinsic::computeBuiltInTypes` is completely unnecessary. This commit removes the redundant logic. This is the 4th commit of a patch-set that aims to change the default policy for RVV intrinsics from TAMU to TAMA. Please refer to the cover letter in the 1st commit (D141573) for an overview. Reviewed By: craig.topper Differential Revision: https://reviews.llvm.org/D141577 --- diff --git a/clang/lib/Support/RISCVVIntrinsicUtils.cpp b/clang/lib/Support/RISCVVIntrinsicUtils.cpp index 18b8ca5..d67221e 100644 --- a/clang/lib/Support/RISCVVIntrinsicUtils.cpp +++ b/clang/lib/Support/RISCVVIntrinsicUtils.cpp @@ -918,12 +918,6 @@ llvm::SmallVector RVVIntrinsic::computeBuiltinTypes( // Update PolicyAttrs if need (TA or TAMA) for compute builtin types. if (PolicyAttrs.isMAPolicy()) PolicyAttrs.TailPolicy = Policy::PolicyType::Agnostic; // TAMA - if (PolicyAttrs.isUnspecified()) { - if (!IsMasked) { - PolicyAttrs.IsUnspecified = false; - PolicyAttrs.TailPolicy = Policy::PolicyType::Agnostic; // TA - } - } bool HasPassthruOp = DefaultScheme == PolicyScheme::HasPassthruOperand; if (IsMasked) { // If HasMaskedOffOperand, insert result type as first input operand if