Skip to content

Commit

Permalink
Update SerializationString.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
alexey-milovidov committed Dec 12, 2023
1 parent 6b1acf7 commit 6cab012
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/DataTypes/Serializations/SerializationString.cpp
Expand Up @@ -152,6 +152,7 @@ template <int UNROLL_TIMES>
static NO_INLINE void deserializeBinarySSE2(ColumnString::Chars & data, ColumnString::Offsets & offsets, ReadBuffer & istr, size_t limit)
{
size_t offset = data.size();
/// Avoiding calling resize in a loop improves the performance.
data.resize(std::max(data.capacity(), static_cast<size_t>(4096)));

for (size_t i = 0; i < limit; ++i)
Expand Down

0 comments on commit 6cab012

Please sign in to comment.