| From: | Marti Raudsepp <marti(at)juffo(dot)org> |
|---|---|
| To: | Fujii Masao <masao(dot)fujii(at)gmail(dot)com> |
| Cc: | Simon Riggs <simon(at)2ndquadrant(dot)com>, Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, pgsql-hackers(at)postgresql(dot)org, Daniel Farina <daniel(at)heroku(dot)com> |
| Subject: | Re: Sync Rep v17 |
| Date: | 2011-02-22 08:59:21 |
| Message-ID: | AANLkTimsfNE2H4xaY6cwiyp5i7JDMwpx3ZZTucYp=KT-@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Tue, Feb 22, 2011 at 07:38, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
> + SpinLockAcquire(&WalSndCtl->ctlmutex);
> + result = WalSndCtl->sync_rep_service_available;
> + SpinLockRelease(&WalSndCtl->ctlmutex);
> volatile pointer needs to be used to prevent code rearrangement.
I don't think that's necessary. Spinlock functions already prevent
reordering using __asm__ __volatile__
Otherwise, surely they would be utterly broken?
Regards,
Marti
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Cédric Villemain | 2011-02-22 09:11:49 | Re: UNLOGGED tables in psql \d |
| Previous Message | Heikki Linnakangas | 2011-02-22 07:10:13 | Re: Snapshot synchronization, again... |