Parallel Sequence Scan doubts - Mailing list pgsql-hackers

From Haribabu Kommi
Subject Parallel Sequence Scan doubts
Date
Msg-id CAJrrPGcSWfKp1Mpmgj+Y4WdYc2VaH7nPRkNuirAgK9oSuYRpGw@mail.gmail.com
Whole thread Raw
Responses Re: Parallel Sequence Scan doubts
Re: Parallel Sequence Scan doubts
List pgsql-hackers
Corrected subject.

Hi Hackers,

Implementation of "Parallel Sequence Scan"

Approach:

1."Parallel Sequence Scan" can achieved by using the background
workers doing the job of actual sequence scan including the
qualification check also.

2. Planner generates the parallel scan plan by checking the possible
criteria of the table to do a parallel scan and generates the tasks
(range of blocks).

3. In the executor Init phase, Try to copy the necessary data required
by the workers and start the workers.

4. In the executor run phase, just get the tuples which are sent by
the workers and process them further in the plan node execution.

some of the problems i am thinking:

1. Data structures that are required to be copied from backend to
worker are currentTransactionState, Snapshot, GUC, ComboCID, Estate
and etc.

I see some problems in copying "Estate" data structure into the shared
memory because it contains so many pointers. There is a need of some
infrastructure to copy these data structures into the shared memory.

If the backend takes care of locking the relation and there are no sub
plans involved in the qual and targetlist, is the estate is really
required in the worker to achieve the parallel scan?

Is it possible to Initialize the qual, targetlist and projinfo with
the local "Estate" structure created in the worker with the help of
"plan" structure received from the backend?

Or

In case if "estate" is required in the worker for the processing, is
there any better way possible to share backend data structures with
the workers?

Any suggestions?

Regards,
Hari Babu
Fujitsu Australia



pgsql-hackers by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: WIP Patch for GROUPING SETS phase 1
Next
From: Dilip kumar
Date:
Subject: Re: TODO : Allow parallel cores to be used by vacuumdb [ WIP ]