- Notifications
You must be signed in to change notification settings - Fork5
Commite85a01d
committed
Clean up the representation of special snapshots by including a "method
pointer" in every Snapshot struct. This allows removal of the case-by-casetests in HeapTupleSatisfiesVisibility, which should make it a bit faster(I didn't try any performance tests though). More importantly, we are nolonger violating portable C practices by assuming that small integers aredistinct from all pointer values, and HeapTupleSatisfiesDirty no longerhas a non-reentrant API involving side-effects on a global variable.There were a couple of places calling HeapTupleSatisfiesXXX routinesdirectly rather than through the HeapTupleSatisfiesVisibility macro.Since these places had to be changed anyway, I chose to make them gothrough the macro for uniformity.Along the way I renamed HeapTupleSatisfiesSnapshot to HeapTupleSatisfiesMVCCto emphasize that it's only used with MVCC-type snapshots. I was sorelytempted to rename HeapTupleSatisfiesVisibility to HeapTupleSatisfiesSnapshot,but forebore for the moment to avoid confusion and reduce the likelihood thatthis patch breaks some of the pending patches. Might want to reconsiderdoing that later.1 parent75c6519 commite85a01d
File tree
10 files changed
+148
-121
lines changed- contrib/pgstattuple
- src
- backend
- access
- heap
- nbtree
- catalog
- executor
- storage/ipc
- utils
- adt
- time
- include/utils
10 files changed
+148
-121
lines changedLines changed: 3 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 | 1 |
| |
2 |
| - | |
| 2 | + | |
3 | 3 |
| |
4 | 4 |
| |
5 | 5 |
| |
| |||
256 | 256 |
| |
257 | 257 |
| |
258 | 258 |
| |
259 |
| - | |
| 259 | + | |
260 | 260 |
| |
261 | 261 |
| |
262 |
| - | |
| 262 | + | |
263 | 263 |
| |
264 | 264 |
| |
265 | 265 |
| |
|
Lines changed: 3 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
11 |
| - | |
| 11 | + | |
12 | 12 |
| |
13 | 13 |
| |
14 | 14 |
| |
| |||
1706 | 1706 |
| |
1707 | 1707 |
| |
1708 | 1708 |
| |
1709 |
| - | |
| 1709 | + | |
1710 | 1710 |
| |
1711 | 1711 |
| |
1712 | 1712 |
| |
| |||
2025 | 2025 |
| |
2026 | 2026 |
| |
2027 | 2027 |
| |
2028 |
| - | |
| 2028 | + | |
2029 | 2029 |
| |
2030 | 2030 |
| |
2031 | 2031 |
| |
|
Lines changed: 7 additions & 4 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
11 |
| - | |
| 11 | + | |
12 | 12 |
| |
13 | 13 |
| |
14 | 14 |
| |
| |||
176 | 176 |
| |
177 | 177 |
| |
178 | 178 |
| |
| 179 | + | |
179 | 180 |
| |
180 | 181 |
| |
181 | 182 |
| |
182 | 183 |
| |
183 | 184 |
| |
| 185 | + | |
| 186 | + | |
184 | 187 |
| |
185 | 188 |
| |
186 | 189 |
| |
| |||
232 | 235 |
| |
233 | 236 |
| |
234 | 237 |
| |
235 |
| - | |
| 238 | + | |
236 | 239 |
| |
237 | 240 |
| |
238 | 241 |
| |
239 | 242 |
| |
240 |
| - | |
241 |
| - | |
| 243 | + | |
| 244 | + | |
242 | 245 |
| |
243 | 246 |
| |
244 | 247 |
| |
|
Lines changed: 5 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
10 | 10 |
| |
11 | 11 |
| |
12 | 12 |
| |
13 |
| - | |
| 13 | + | |
14 | 14 |
| |
15 | 15 |
| |
16 | 16 |
| |
| |||
361 | 361 |
| |
362 | 362 |
| |
363 | 363 |
| |
| 364 | + | |
364 | 365 |
| |
365 | 366 |
| |
366 | 367 |
| |
367 | 368 |
| |
| 369 | + | |
| 370 | + | |
368 | 371 |
| |
369 | 372 |
| |
370 | 373 |
| |
| |||
377 | 380 |
| |
378 | 381 |
| |
379 | 382 |
| |
380 |
| - | |
| 383 | + | |
381 | 384 |
| |
382 | 385 |
| |
383 | 386 |
| |
|
Lines changed: 4 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
11 |
| - | |
| 11 | + | |
12 | 12 |
| |
13 | 13 |
| |
14 | 14 |
| |
| |||
1828 | 1828 |
| |
1829 | 1829 |
| |
1830 | 1830 |
| |
1831 |
| - | |
| 1831 | + | |
1832 | 1832 |
| |
1833 | 1833 |
| |
1834 |
| - | |
| 1834 | + | |
| 1835 | + | |
1835 | 1836 |
| |
1836 | 1837 |
| |
1837 | 1838 |
| |
|
Lines changed: 7 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
26 | 26 |
| |
27 | 27 |
| |
28 | 28 |
| |
29 |
| - | |
| 29 | + | |
30 | 30 |
| |
31 | 31 |
| |
32 | 32 |
| |
| |||
1893 | 1893 |
| |
1894 | 1894 |
| |
1895 | 1895 |
| |
| 1896 | + | |
1896 | 1897 |
| |
1897 | 1898 |
| |
1898 | 1899 |
| |
| |||
1925 | 1926 |
| |
1926 | 1927 |
| |
1927 | 1928 |
| |
| 1929 | + | |
1928 | 1930 |
| |
1929 | 1931 |
| |
1930 | 1932 |
| |
1931 | 1933 |
| |
1932 | 1934 |
| |
1933 |
| - | |
| 1935 | + | |
1934 | 1936 |
| |
1935 | 1937 |
| |
1936 | 1938 |
| |
| |||
1948 | 1950 |
| |
1949 | 1951 |
| |
1950 | 1952 |
| |
1951 |
| - | |
| 1953 | + | |
1952 | 1954 |
| |
1953 | 1955 |
| |
1954 | 1956 |
| |
1955 | 1957 |
| |
1956 | 1958 |
| |
1957 | 1959 |
| |
1958 |
| - | |
| 1960 | + | |
1959 | 1961 |
| |
1960 | 1962 |
| |
1961 |
| - | |
| 1963 | + | |
1962 | 1964 |
| |
1963 | 1965 |
| |
1964 | 1966 |
| |
|
Lines changed: 2 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
23 | 23 |
| |
24 | 24 |
| |
25 | 25 |
| |
26 |
| - | |
| 26 | + | |
27 | 27 |
| |
28 | 28 |
| |
29 | 29 |
| |
| |||
484 | 484 |
| |
485 | 485 |
| |
486 | 486 |
| |
487 |
| - | |
| 487 | + | |
488 | 488 |
| |
489 | 489 |
| |
490 | 490 |
| |
|
Lines changed: 5 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
15 | 15 |
| |
16 | 16 |
| |
17 | 17 |
| |
18 |
| - | |
| 18 | + | |
19 | 19 |
| |
20 | 20 |
| |
21 | 21 |
| |
| |||
277 | 277 |
| |
278 | 278 |
| |
279 | 279 |
| |
280 |
| - | |
| 280 | + | |
281 | 281 |
| |
282 | 282 |
| |
283 |
| - | |
284 |
| - | |
| 283 | + | |
| 284 | + | |
285 | 285 |
| |
286 | 286 |
| |
287 | 287 |
| |
288 | 288 |
| |
289 | 289 |
| |
290 | 290 |
| |
291 | 291 |
| |
292 |
| - | |
| 292 | + | |
293 | 293 |
| |
294 | 294 |
| |
295 | 295 |
| |
|
0 commit comments
Comments
(0)