Re: [v9.1] sepgsql - userspace access vector cache

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Kohei Kaigai <Kohei(dot)Kaigai(at)emea(dot)nec(dot)com>
Cc: Yeb Havinga <yebhavinga(at)gmail(dot)com>, Kohei KaiGai <kaigai(at)kaigai(dot)gr(dot)jp>, PgHacker <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [v9.1] sepgsql - userspace access vector cache
Date: 2011-07-20 16:45:44
Message-ID: CA+TgmoaGSeAubtYh4f-ONznCHcb7sa7eU3sTj2wM4s3zANZcfg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Jul 20, 2011 at 12:40 PM, Kohei Kaigai
<Kohei(dot)Kaigai(at)emea(dot)nec(dot)com> wrote:
> One question is why InitCatalogCache() should be invoked from InitPostgres()?
> If we initialize syscache on starting up postmaster process, I think
> all the syscache buckets will be ready on child process forks, and
> unused syscache does not consume physical memory, even if security
> label acquire 2048 of buckets.

Most of the overhead seems to be the cost of the page faults required
for the kernel to map the relevant pages into the process address
space. After a fork(), all those pages become copy-on-write, so if
the syscaches are actually used this doesn't save much of anything.
In the specific case of sepgsql it would help, though, because what
you're proposing is to add a syscache that will in most cases never be
accessed at all. We'd still have a problem in the EXEC_BACKEND (i.e.
Windows) case, however...

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kohei Kaigai 2011-07-20 17:00:30 Re: [v9.1] sepgsql - userspace access vector cache
Previous Message Kohei Kaigai 2011-07-20 16:40:06 Re: [v9.1] sepgsql - userspace access vector cache