Op Saturday 26 July 2008 23:09:06 schreef eks dev: > what is the reason to have HeapedScorerDoc class in ScorerDocQueue? > Caching of the doc value?
Yes. The underlying priority queue does log2(n) comparisons on them on some occasions. > Does this bring anything compared to > invoking doc() on Scorer, just curious, maybe I do not see something > ovious... If doc is the reason, I would bet on doc() Around 2005 it used to bring a bit of performance, but the latest JIT's don't seem to need such hand holding anymore. I'm considering to remove the cached queue size where the ScorerDocQueue is used, so I might as well try and remove this doc value caching. Regards, Paul Elschot --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]