[MDEV-16159] Use atomic memory access for purge_sys Created: 2018-05-14 Updated: 2018-05-16 Resolved: 2018-05-16 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Storage Engine - InnoDB |
| Fix Version/s: | 10.3.7 |
| Type: | Task | Priority: | Major |
| Reporter: | Marko Mäkelä | Assignee: | Marko Mäkelä |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | performance, race | ||
| Issue Links: |
|
||||||||||||
| Description |
|
This refactoring is motivated by The variables purge_sys.state and purge_sys.running are sometimes being read without proper protection, and sometimes read while unnecessarily holding purge_sys.latch exclusively. It is cleaner to use a combination of purge_sys.latch and atomic memory access for writes, so that reads can use either protection. |