[
https://issues.apache.org/jira/browse/LUCENE-3178?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13549567#comment-13549567
]
Uwe Schindler commented on LUCENE-3178:
---------------------------------------
I think this is largely related to Robert's comment:
bq. Might be interesting to revisit now that we use block compression that
doesn't readByte(), readByte(), readByte() and hopefully avoids some of the
bounds checks and so on that I think it helped with.
Since we moved to block codecs, the use of single-byte get's on the byte buffer
is largely reduced. It now just reads blocks of data, so MappedByteBuffer can
do that efficently using a memcpy(). Some MTQs are still faster because they
read much more blocks for a large number of terms. I would have expected no
significant speed up at all for, e.g., NRQ.
Additionally, when using the ByteBuffer methods to get bytes, I think newer
java versions use intrinsics, that may no longer be used with your directory
impl.
I would not provide a custom MMapDir at all, it is too risky and does not
really brings a large speed up anymore (Java 7 + block postings).
> Native MMapDir
> --------------
>
> Key: LUCENE-3178
> URL: https://issues.apache.org/jira/browse/LUCENE-3178
> Project: Lucene - Core
> Issue Type: Improvement
> Components: core/store
> Reporter: Michael McCandless
> Labels: gsoc2012, lucene-gsoc-12
> Attachments: LUCENE-3178-Native-MMap-implementation.patch,
> LUCENE-3178-Native-MMap-implementation.patch,
> LUCENE-3178-Native-MMap-implementation.patch
>
>
> Spinoff from LUCENE-2793.
> Just like we will create native Dir impl (UnixDirectory) to pass the right OS
> level IO flags depending on the IOContext, we could in theory do something
> similar with MMapDir.
> The problem is MMap is apparently quite hairy... and to pass the flags the
> native code would need to invoke mmap (I think?), unlike UnixDir where the
> code "only" has to open the file handle.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]