- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit1e0dfd1
committed
Add Valgrind buffer access instrumentation.
Teach Valgrind memcheck to maintain the "defined-ness" of each sharedbuffer based on whether the backend holds at least one pin at the pointit is accessed by access method code. Bugs like the one fixed by commitb0229f2 can be detected using this new instrumentation.Note that backends running with Valgrind naturally have their ownindependent ideas about whether any given byte in shared memory is safeor unsafe to access. There is no risk that concurrent access bymultiple backends to the same shared memory will confuse Valgrind'sinstrumentation, because everything already works at the process level(or at the memory mapping level, if you prefer).Author: Álvaro Herrera, Peter GeogheganReviewed-By: Anastasia LubennikovaDiscussion:https://postgr.es/m/20150723195349.GW5596@postgresql.orgDiscussion:https://postgr.es/m/CAH2-WzkLgyN3zBvRZ1pkNJThC=xi_0gpWRUb_45eexLH1+k2_Q@mail.gmail.com1 parentf009591 commit1e0dfd1
File tree
2 files changed
+25
-6
lines changed- src
- backend/storage/buffer
- include
2 files changed
+25
-6
lines changedLines changed: 18 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
49 | 49 |
| |
50 | 50 |
| |
51 | 51 |
| |
| 52 | + | |
52 | 53 |
| |
53 | 54 |
| |
54 | 55 |
| |
| |||
1633 | 1634 |
| |
1634 | 1635 |
| |
1635 | 1636 |
| |
| 1637 | + | |
| 1638 | + | |
| 1639 | + | |
| 1640 | + | |
| 1641 | + | |
| 1642 | + | |
| 1643 | + | |
1636 | 1644 |
| |
1637 | 1645 |
| |
1638 | 1646 |
| |
| |||
1683 | 1691 |
| |
1684 | 1692 |
| |
1685 | 1693 |
| |
| 1694 | + | |
| 1695 | + | |
| 1696 | + | |
| 1697 | + | |
| 1698 | + | |
| 1699 | + | |
| 1700 | + | |
1686 | 1701 |
| |
1687 | 1702 |
| |
1688 | 1703 |
| |
| |||
1728 | 1743 |
| |
1729 | 1744 |
| |
1730 | 1745 |
| |
| 1746 | + | |
| 1747 | + | |
| 1748 | + | |
1731 | 1749 |
| |
1732 | 1750 |
| |
1733 | 1751 |
| |
|
Lines changed: 7 additions & 6 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
269 | 269 |
| |
270 | 270 |
| |
271 | 271 |
| |
272 |
| - | |
273 |
| - | |
274 |
| - | |
275 |
| - | |
276 |
| - | |
277 |
| - | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
278 | 279 |
| |
279 | 280 |
| |
280 | 281 |
| |
|
0 commit comments
Comments
(0)