Skip to content

armgit / solr

Public Imported from GitHub
0

Apache Solr open-source search software

add TODO

Robert Muir2212440b3bef
diff --git a/lucene/core/src/java/org/apache/lucene/util/packed/AppendingLongBuffer.java b/lucene/core/src/java/org/apache/lucene/util/packed/AppendingLongBuffer.java
index 3af537c1a75..cb96829f02d 100644
--- a/lucene/core/src/java/org/apache/lucene/util/packed/AppendingLongBuffer.java
+++ b/lucene/core/src/java/org/apache/lucene/util/packed/AppendingLongBuffer.java
@@ -160,6 +160,7 @@ public class AppendingLongBuffer {
* Return the number of bytes used by this instance.
*/
public long ramBytesUsed() {
+ // TODO: this is called per-doc-per-norms/dv-field, can we optimize this?
long bytesUsed = RamUsageEstimator.alignObjectSize(
RamUsageEstimator.NUM_BYTES_OBJECT_HEADER
+ 3 * RamUsageEstimator.NUM_BYTES_OBJECT_REF // the 3 arrays