Usage of planner_ctx

From: Amit Kapila <amit(dot)kapila(at)huawei(dot)com>
To: 'PostgreSQL-development' <pgsql-hackers(at)postgresql(dot)org>
Subject: Usage of planner_ctx
Date: 2012-04-24 06:27:35
Message-ID: 000401cd21e3$57338760$059a9620$%kapila@huawei.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

PlannerInfo->planner_ctx is assigned with either MessageContext or
PortalHeapMemory depending on the flow from which planner is invoked.

My doubt is that during whole planning process till the Plan is stored in
PlannedStmt, all the memory is from CurrentMemoryContext which is same as
PlannerInfo->planner_ctx.

So what is the use of having PlannerInfo->planner_ctx which only contains
CurrentMemoryContext?

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kyotaro HORIGUCHI 2012-04-24 06:47:57 Re: [BUG] Checkpointer on hot standby runs without looking checkpoint_segments
Previous Message Robert Haas 2012-04-24 02:07:29 Re: Aggressive memory consumption in {ts,array}_typanalyze