dungba88 commented on code in PR #12738: URL: https://github.com/apache/lucene/pull/12738#discussion_r1377778426
########## lucene/core/src/java/org/apache/lucene/util/fst/NodeHash.java: ########## @@ -214,7 +222,13 @@ private long hash(long node) throws IOException { * Compares an unfrozen node (UnCompiledNode) with a frozen node at byte location address (long), * returning true if they are equal. */ - private boolean nodesEqual(FSTCompiler.UnCompiledNode<T> node, long address) throws IOException { + private boolean nodesEqual( + PagedGrowableHash table, FSTCompiler.UnCompiledNode<T> node, long address) + throws IOException { + // nocommit: this is non-optimal, we should have a BytesReader that wraps and read the + // ByteBlockPool directly + byte[] bytes = table.getBytes(address); Review Comment: I ended up storing the relative differences between the global address and the ByteBlockPool address. It retains the existing behavior of FST operation (which always rely on the global address). See the `ByteBlockPoolReverseBytesReader` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org