Skip site navigation (1) Skip section navigation (2)

pgsql: Minor speed hacks in AllocSetReset: avoid clearing the freelist

From: tgl(at)svr1(dot)postgresql(dot)org (Tom Lane)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Minor speed hacks in AllocSetReset: avoid clearing the freelist
Date: 2005-05-14 20:29:14
Message-ID: 20050514202914.0CB235388B@svr1.postgresql.org (view raw or flat)
Thread:
Lists: pgsql-committers
Log Message:
-----------
Minor speed hacks in AllocSetReset: avoid clearing the freelist headers
when the blocks list is empty (there can surely be no freelist items if
the context contains no memory), and use MemSetAligned not MemSet to
clear the headers (we assume alignof(pointer) >= alignof(int32)).
Per discussion with Atsushi Ogawa.  He proposes some further hacking
that I'm not yet sold on, but these two changes are unconditional wins
since there is no case in which they make things slower.

Modified Files:
--------------
    pgsql/src/backend/utils/mmgr:
        aset.c (r1.59 -> r1.60)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/mmgr/aset.c.diff?r1=1.59&r2=1.60)

pgsql-committers by date

Next:From: Tom LaneDate: 2005-05-14 21:29:23
Subject: pgsql: Minor refactoring to eliminate duplicate code and make startup a
Previous:From: Tom LaneDate: 2005-05-14 17:55:23
Subject: pgsql: Convert the existing regression test scripts for the various

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group