Don't let protected variable access to be reordered after spinlock release.
LWLockAcquireWithVar needs to set the protected variable while holding
the spinlock. Need to use a volatile pointer to make sure it doesn't get
reordered by the compiler. The other functions that accessed the protected
variable already got this right.
9.4 only. Earlier releases didn't have this code, and in master, spinlock
release acts as a compiler barrier.
Branch
------
REL9_4_STABLE
Details
-------
http://git.postgresql.org/pg/commitdiff/4971c36b46c63c0b36a38df6a4b6ad9f303e4620
Modified Files
--------------
src/backend/storage/lmgr/lwlock.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
Есть вопросы? Напишите нам!
Соглашаюсь с условиями обработки персональных данных
✖
By continuing to browse this website, you agree to the use of cookies. Go to Privacy Policy.