You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tinkerpop.apache.org by "Marko A. Rodriguez (JIRA)" <ji...@apache.org> on 2016/10/13 13:55:20 UTC

[jira] [Created] (TINKERPOP-1503) TraverserSet initial size should be specified for barriers.

Marko A. Rodriguez created TINKERPOP-1503:
---------------------------------------------

             Summary: TraverserSet initial size should be specified for barriers.
                 Key: TINKERPOP-1503
                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1503
             Project: TinkerPop
          Issue Type: Improvement
          Components: benchmark, process
    Affects Versions: 3.2.2
            Reporter: Marko A. Rodriguez


{{TraverserSet}} is one of the most important objects in the Gremlin traversal machine. Each step is backed by a {{TraverserSet}}. Typically, steps will have only a few traversers ever in their set, but some steps can have lots. Examples include: RepeatStep, NoOpBarrierStep, OrderGlobalStep, DedupGlobalStep, SampleGlobalStep, LambdaCollectingBarrierStep...

In particular, I'm looking at {{NoOpBarrierStep}} as that is used extensively as an optimization by LazyBarrierStrategy, PathRetractionStrategy, RepeatUnrollStrategy. If we already know the max size of the barrier, we should be setting the "initial size" of the {{TraverserSet}} (which is basically a wrapper around a {{LinkedHashMap}}). The default of 16 seems not smart. Perhaps [~twilmes] or [~mbroecheler] have some thoughts on what the initial size of the {{LinkedHashMap}} should be given a known {{maxBarrierSize}}. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)