Re: Should we cacheline align PGXACT?

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Alexander Korotkov <a(dot)korotkov(at)postgrespro(dot)ru>, Bernd Helmle <mailings(at)oopsware(dot)de>, Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Should we cacheline align PGXACT?
Date: 2017-02-20 12:32:41
Views: Raw Message | Whole Thread | Download mbox
Lists: pgsql-hackers

On 15 February 2017 at 19:15, Andres Freund <andres(at)anarazel(dot)de> wrote:

> I think I previously
> mentioned, even just removing the MyPgXact->xmin assignment in
> SnapshotResetXmin() is measurable performance wise and cache-hit ratio
> wise.

Currently, we issue SnapshotResetXmin() pointlessly at end of xact, so
patch attached to remove that call, plus some comments to explain
that. This reduces the cause.

Also, another patch to reduce the calls to SnapshotResetXmin() using a
simple heuristic to reduce the effects.

Simon Riggs
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachment Content-Type Size
skip_SnapshotResetXmin_if_idle_timeout.v1.patch application/octet-stream 1.0 KB
reduce_pgxact_access_AtEOXact.v1.patch application/octet-stream 3.4 KB

In response to


Browse pgsql-hackers by date

  From Date Subject
Next Message Aleksander Alekseev 2017-02-20 12:41:24 Re: SCRAM authentication, take three
Previous Message Aleksander Alekseev 2017-02-20 12:15:14 Re: SCRAM authentication, take three