[
https://issues.apache.org/jira/browse/LUCENE-9404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17135303#comment-17135303
]
Robert Muir commented on LUCENE-9404:
-------------------------------------
I thought about this when looking at benchmark results from
https://github.com/benalexau/hash-bench and playing with LUCENE-9403
The crc code screams for the different cases, and this JDK method already has
the .hasArray etc logic and optimizations.
> simplify checksum calculation of ByteBuffersIndexOutput
> -------------------------------------------------------
>
> Key: LUCENE-9404
> URL: https://issues.apache.org/jira/browse/LUCENE-9404
> Project: Lucene - Core
> Issue Type: Improvement
> Reporter: Robert Muir
> Priority: Major
> Attachments: LUCENE-9404.patch
>
>
> I think this class can avoid its current logic/copying and just call
> CRC32.update(ByteBuffer) which is optimized for both array and direct buffers?
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]