Re: 7.1 vs. 7.2 on AIX 5L

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp>
Cc: ZeugswetterA(at)spardat(dot)at, tgl(at)sss(dot)pgh(dot)pa(dot)us, pgsql-hackers(at)postgresql(dot)org
Subject: Re: 7.1 vs. 7.2 on AIX 5L
Date: 2002-01-24 23:35:12
Message-ID: 200201242335.g0ONZCi03725@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Added to TODO:

* Evaluate AIX cs() spinlock macro for performance optimizations (Tatsuo)

---------------------------------------------------------------------------

Tatsuo Ishii wrote:
> > > NOTICE: LockRelease: no such lock
> > >
> > > I'm afraid now the locking is broken. Will look into more.
> >
> > Next try would be _check_lock (found in sys/atomic_op.h):
> >
> > Description (from man page)
> >
> > The _check_lock subroutine performs an atomic (uninterruptible) sequence of
> > operations. The compare_and_swap subroutine is similar, but does not issue
> > synchronization instructions and therefore is inappropriate for updating lock
> > words.
> >
> > replace the TAS define with:
> > #define TAS(lock) _check_lock(lock, 0, 1)
> >
> > > with LinuxPPC asm: 2m9.340s
> > > with cs: 10m11.15s
> > > with fetch_and_or: 3m55.19s
> >
> > with _check_lock: 3m29.990s
> >
> > I think that the culprit may also be the S_UNLOCK (use _clear_lock) ?
>
> Thanks. I will try with it.
>
> BTW, I'm still wondering why 7.2 is slower than 7.1 on AIX. Tom said
> cs() is responsible for that. But not only 7.2 but 7.1 uses cs(). It
> seems cs() does not explain the difference of the performance.
> --
> Tatsuo Ishii
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Justin Clift 2002-01-25 00:25:37 Re: PostgreSQL crashes with Qmail-SQL
Previous Message Tom Lane 2002-01-24 23:10:10 Re: Ready for RC2 I guess...