1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-11-21 09:20:51 +03:00

fix(perf): add reserves for usage of vector filled after creation

This commit is contained in:
Leonid Fedorov
2025-10-23 14:49:17 +00:00
committed by Leonid Fedorov
parent 87bdc5fcb0
commit 7d23514315
29 changed files with 220 additions and 14 deletions

View File

@@ -1234,6 +1234,8 @@ class RowGroupStorage
void getTmpFilePrefixes(std::vector<std::string>& prefixes) const
{
char buf[PATH_MAX];
// Reserve space for 2 prefixes
prefixes.reserve(prefixes.size() + 2);
snprintf(buf, sizeof(buf), "Agg-p%u-t%p-rg", getpid(), fUniqId);
prefixes.emplace_back(buf);