[llvm] c640f97 - [TableGen] Don't use inline storage for ReferenceLocs (NFC) (#125231)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 31 12:27:12 PST 2025
Author: Nikita Popov
Date: 2025-01-31T21:27:09+01:00
New Revision: c640f97ccf723e64ff24af225cb995c905538406
URL: https://github.com/llvm/llvm-project/commit/c640f97ccf723e64ff24af225cb995c905538406
DIFF: https://github.com/llvm/llvm-project/commit/c640f97ccf723e64ff24af225cb995c905538406.diff
LOG: [TableGen] Don't use inline storage for ReferenceLocs (NFC) (#125231)
The ReferenceLocs are not enabled by default (they are used by the
tablegen lsp server), and as such always empty, but still allocate
inline storage for the SmallVector. Disabling it saves about 200MB on
RISCVGenGlobalISel.inc.
(The equivalent field in Record already disables inline storage.)
Added:
Modified:
llvm/include/llvm/TableGen/Record.h
Removed:
################################################################################
diff --git a/llvm/include/llvm/TableGen/Record.h b/llvm/include/llvm/TableGen/Record.h
index d9930a48e80840..e04ed348231487 100644
--- a/llvm/include/llvm/TableGen/Record.h
+++ b/llvm/include/llvm/TableGen/Record.h
@@ -1523,7 +1523,7 @@ class RecordVal {
bool IsUsed = false;
/// Reference locations to this record value.
- SmallVector<SMRange> ReferenceLocs;
+ SmallVector<SMRange, 0> ReferenceLocs;
public:
RecordVal(const Init *N, const RecTy *T, FieldKind K);
More information about the llvm-commits
mailing list