Skip to content

Commit 2c8010a

Browse files
committed
feat(query): add comment
1 parent b30de88 commit 2c8010a

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

src/query/functions-v2/src/aggregates/aggregate_distinct_state.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,7 @@ impl AggregateDistinctStringState {
161161
let data = unsafe { key.as_slice() };
162162

163163
let holder = self.holders.last_mut().unwrap();
164+
// TODO(sundy): may cause memory fragmentation, refactor this using arena
164165
if holder.may_resize(data.len()) {
165166
let mut holder = StringColumnBuilder::with_capacity(
166167
HOLDER_CAPACITY,

src/query/functions/src/aggregates/aggregate_distinct_state.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,7 @@ impl AggregateDistinctStringState {
187187
let data = unsafe { key.as_slice() };
188188

189189
let holder = self.holders.last_mut().unwrap();
190+
// TODO(sundy): may cause memory fragmentation, refactor this using arena
190191
if holder.may_resize(data.len()) {
191192
let mut holder = MutableStringColumn::with_values_capacity(
192193
HOLDER_BYTES_CAPACITY.max(data.len()),

0 commit comments

Comments
 (0)