Mailing List Archive

[Lucene] BYTE_BLOCK_SIZE in class ByteBlockPool
Hi,

In class ByteBlockPool , per buffer's default maximum size was set 32KB?2 << 15?, is this such choice relevant with CPU L1 cache which cache size is 32KB?

If not so, could anyone give some tips?
Re: [Lucene] BYTE_BLOCK_SIZE in class ByteBlockPool [ In reply to ]
Hmm I don't think the original selection of this size was due to CPU L1
cache limits. It was more a tradeoff of not wasting too much RAM for tiny
indexing events (e.g. index one small document and then refresh) while
still getting benefits of scale for the more common/important high indexing
rate use-cases.

Maybe try changing it and see if things get faster/slower for your usage?

Mike McCandless

http://blog.mikemccandless.com


On Fri, Apr 2, 2021 at 2:05 AM LuXugang <xuganglu@icloud.com.invalid> wrote:

> Hi,
>
> In class ByteBlockPool , per buffer's default maximum size was set 32KB?2
> << 15?, is this such choice relevant with CPU L1 cache which cache size is
> 32KB?
>
> If not so, could anyone give some tips?
>
>
Re: [Lucene] BYTE_BLOCK_SIZE in class ByteBlockPool [ In reply to ]
Thanks, Michael.

> 2021?4?2? ??10:22?Michael McCandless <lucene@mikemccandless.com <mailto:lucene@mikemccandless.com>> ???
>
> Hmm I don't think the original selection of this size was due to CPU L1 cache limits. It was more a tradeoff of not wasting too much RAM for tiny indexing events (e.g. index one small document and then refresh) while still getting benefits of scale for the more common/important high indexing rate use-cases.
>
> Maybe try changing it and see if things get faster/slower for your usage?
>
> Mike McCandless
>
> http://blog.mikemccandless.com <http://blog.mikemccandless.com/>
>
> On Fri, Apr 2, 2021 at 2:05 AM LuXugang <xuganglu@icloud.com.invalid <mailto:xuganglu@icloud.com.invalid>> wrote:
> Hi,
>
> In class ByteBlockPool , per buffer's default maximum size was set 32KB?2 << 15?, is this such choice relevant with CPU L1 cache which cache size is 32KB?
>
> If not so, could anyone give some tips?
>
> <ByteBlockPool.png>