From: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> |
---|---|
To: | "Wu, Fei" <wufei(dot)fnst(at)cn(dot)fujitsu(dot)com> |
Cc: | "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Confusing comment for function ExecParallelEstimate |
Date: | 2019-06-05 04:20:01 |
Message-ID: | CAA4eK1++AxvgJ-SGOgV2K=1pLuSMHS9Wxx4FokjdGR878K3MOA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jun 5, 2019 at 9:24 AM Wu, Fei <wufei(dot)fnst(at)cn(dot)fujitsu(dot)com> wrote:
>
> Hi, all
>
> Lately I was researching Parallelism of Postgres 10.7(and it is same in all version), and I was confused when reading the comment of function ExecParallelEstimate :
>
> (in src/backend/executor/execParallel.c)
>
> ----------------------------------------------
>
>
>
> * While we're at it, count the number of PlanState nodes in the tree, so
>
> * we know how many SharedPlanStateInstrumentation structures we need.
>
> static bool
>
> ExecParallelEstimate(PlanState *planstate, ExecParallelEstimateContext *e)
>
> ----------------------------------------------
>
>
>
> The structure SharedPlanStateInstrumentation is not exists at all. And I noticed that the so called “SharedPlanStateInstrumentation”
>
> maybe is the structure instrumentation now, which is used for storing information of planstate in parallelism. The function count the number
>
> of planState nodes and stored it in ExecParallelEstimateContext-> nnodes ,then use it to Estimate space for instrumentation structure in
>
> function ExecInitParallelPlan.
>
I think here it refers to SharedExecutorInstrumentation. This
structure is used for accumulating per-PlanState instrumentation. So,
it is not totally wrong, but I guess we can change it to
SharedExecutorInstrumentation to avoid confusion? What do you think?
--
With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com
From | Date | Subject | |
---|---|---|---|
Next Message | Noah Misch | 2019-06-05 05:00:37 | Re: Parallel Append subplan order instability on aye-aye |
Previous Message | Wu, Fei | 2019-06-05 03:54:18 | Confusing comment for function ExecParallelEstimate |