mirror of
https://gitee.com/milvus-io/milvus.git
synced 2025-12-28 22:45:26 +08:00
Fix bug of wrong byte size
Signed-off-by: FluorineDog <guilin.gou@zilliz.com>
This commit is contained in:
parent
fe5f0afe9a
commit
960b79b620
@ -615,9 +615,9 @@ SegmentNaive::GetMemoryUsageInBytes() {
|
||||
total_bytes += vec_ptr->IndexSize();
|
||||
}
|
||||
}
|
||||
int64_t ins_n = (record_.reserved + DefaultElementPerChunk - 1) & (DefaultElementPerChunk - 1);
|
||||
int64_t ins_n = (record_.reserved + DefaultElementPerChunk - 1) & ~(DefaultElementPerChunk - 1);
|
||||
total_bytes += ins_n * (schema_->get_total_sizeof() + 16 + 1);
|
||||
int64_t del_n = (deleted_record_.reserved + DefaultElementPerChunk - 1) & (DefaultElementPerChunk - 1);
|
||||
int64_t del_n = (deleted_record_.reserved + DefaultElementPerChunk - 1) & ~(DefaultElementPerChunk - 1);
|
||||
total_bytes += del_n * (16 * 2);
|
||||
return total_bytes;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user