Author: eopXD Date: 2023-01-24T07:03:33-08:00 New Revision: 1ab7e76887e3c6ff1ca82b3970a0aae71895d848
URL: https://github.com/llvm/llvm-project/commit/1ab7e76887e3c6ff1ca82b3970a0aae71895d848 DIFF: https://github.com/llvm/llvm-project/commit/1ab7e76887e3c6ff1ca82b3970a0aae71895d848.diff LOG: [9/15][Clang][RISCV][NFC] Use correct type for `RVVTypeCache::computeTypes` under RISCVVEmitter.cpp `MaskedPrototype` is initialized and used nowhere, this is a bug. The existing codebase works correctly upon this bug because the default policy for unmasked intrinsics is set to TAMU. This is something to be fixed because when the default policy is changed to TAMA, clang will generate incorrect result. This is the 9th 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: kito-cheng Differential Revision: https://reviews.llvm.org/D141764 Added: Modified: clang/utils/TableGen/RISCVVEmitter.cpp Removed: ################################################################################ diff --git a/clang/utils/TableGen/RISCVVEmitter.cpp b/clang/utils/TableGen/RISCVVEmitter.cpp index 39925cc5c24b4..668e1072c065f 100644 --- a/clang/utils/TableGen/RISCVVEmitter.cpp +++ b/clang/utils/TableGen/RISCVVEmitter.cpp @@ -587,7 +587,7 @@ void RVVEmitter::createRVVIntrinsics( continue; // Create a masked intrinsic std::optional<RVVTypes> MaskTypes = - TypeCache.computeTypes(BT, Log2LMUL, NF, Prototype); + TypeCache.computeTypes(BT, Log2LMUL, NF, MaskedPrototype); Out.push_back(std::make_unique<RVVIntrinsic>( Name, SuffixStr, OverloadedName, OverloadedSuffixStr, MaskedIRName, /*IsMasked=*/true, HasMaskedOffOperand, HasVL, MaskedPolicyScheme, _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits