Modify sinval so that InvalidateSharedInvalid() does not hold
Tom Lane <tgl@sss.pgh.pa.us>
Modify sinval so that InvalidateSharedInvalid() does not hold the SInval spinlock while it is calling the passed invalFunction or resetFunction. This is necessary to avoid deadlock with lmgr change; InvalidateSharedInvalid can be called recursively now. It should be a good performance improvement anyway --- holding a spinlock for more than a very short interval is a no-no.
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/storage/ipc/sinvaladt.c | modified | +68 −74 |
| src/backend/storage/ipc/sinval.c | modified | +42 −15 |
| src/include/storage/sinvaladt.h | modified | +4 −4 |