[clang] [RISCV][clang] Optimize memory usage of intrinsic lookup table (PR #77487)
Craig Topper via cfe-commits
cfe-commits at lists.llvm.org
Tue Jan 9 16:52:39 PST 2024
================
@@ -380,14 +380,14 @@ void RISCVIntrinsicManagerImpl::InitRVVIntrinsic(
OverloadedName += "_" + OverloadedSuffixStr.str();
// clang built-in function name, e.g. __builtin_rvv_vadd.
- std::string BuiltinName = "__builtin_rvv_" + std::string(Record.Name);
+ std::string BuiltinName = std::string(Record.Name);
RVVIntrinsic::updateNamesAndPolicy(IsMasked, HasPolicy, Name, BuiltinName,
OverloadedName, PolicyAttrs,
Record.HasFRMRoundModeOp);
// Put into IntrinsicList.
- uint32_t Index = IntrinsicList.size();
+ uint16_t Index = IntrinsicList.size();
----------------
topperc wrote:
Can you add an assert that makes sure this fits in 16 bits? How close are we to the limit?
https://github.com/llvm/llvm-project/pull/77487
More information about the cfe-commits
mailing list