- Notifications
You must be signed in to change notification settings - Fork28
Commit1efc7e5
committed
Fix problems with ParamListInfo serialization mechanism.
Commitd1b7c1f introduced a mechanismfor serializing a ParamListInfo structure to be passed to a parallelworker. However, this mechanism failed to handle external expandedvalues, as pointed out by Noah Misch. Repair.Moreover, plpgsql_param_fetch requires adjustment because theserialization mechanism needs it to skip evaluating unused parametersjust as we would do when it is called from copyParamList, but params== estate->paramLI in that case. To fix, make the bms_is_member testin that function unconditional.Finally, have setup_param_list set a new ParamListInfo field,paramMask, to the parameters actually used in the expression, so thatwe don't try to fetch those that are not needed when serializing aparameter list. This isn't necessary for correctness, but it makesthe performance of the parallel executor code comparable to what wedo for cases involving cursors.Design suggestions and extensive review by Noah Misch. Patch by me.1 parentbf25fb2 commit1efc7e5
File tree
8 files changed
+89
-29
lines changed- src
- backend
- commands
- executor
- nodes
- tcop
- utils/adt
- include/nodes
- pl/plpgsql/src
8 files changed
+89
-29
lines changedLines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
392 | 392 |
| |
393 | 393 |
| |
394 | 394 |
| |
| 395 | + | |
395 | 396 |
| |
396 | 397 |
| |
397 | 398 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
910 | 910 |
| |
911 | 911 |
| |
912 | 912 |
| |
| 913 | + | |
913 | 914 |
| |
914 | 915 |
| |
915 | 916 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2330 | 2330 |
| |
2331 | 2331 |
| |
2332 | 2332 |
| |
| 2333 | + | |
2333 | 2334 |
| |
2334 | 2335 |
| |
2335 | 2336 |
| |
|
Lines changed: 43 additions & 11 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
15 | 15 |
| |
16 | 16 |
| |
17 | 17 |
| |
| 18 | + | |
18 | 19 |
| |
19 | 20 |
| |
20 | 21 |
| |
| |||
50 | 51 |
| |
51 | 52 |
| |
52 | 53 |
| |
| 54 | + | |
53 | 55 |
| |
54 | 56 |
| |
55 | 57 |
| |
| |||
58 | 60 |
| |
59 | 61 |
| |
60 | 62 |
| |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
61 | 74 |
| |
62 | 75 |
| |
63 | 76 |
| |
| |||
90 | 103 |
| |
91 | 104 |
| |
92 | 105 |
| |
| 106 | + | |
93 | 107 |
| |
94 | 108 |
| |
95 | 109 |
| |
96 |
| - | |
97 |
| - | |
98 |
| - | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
99 | 121 |
| |
100 | 122 |
| |
101 | 123 |
| |
102 | 124 |
| |
103 | 125 |
| |
104 |
| - | |
105 |
| - | |
| 126 | + | |
| 127 | + | |
106 | 128 |
| |
107 | 129 |
| |
108 | 130 |
| |
| |||
150 | 172 |
| |
151 | 173 |
| |
152 | 174 |
| |
| 175 | + | |
153 | 176 |
| |
154 | 177 |
| |
155 | 178 |
| |
156 |
| - | |
157 |
| - | |
158 |
| - | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
159 | 190 |
| |
160 | 191 |
| |
161 |
| - | |
| 192 | + | |
162 | 193 |
| |
163 | 194 |
| |
164 | 195 |
| |
165 | 196 |
| |
166 | 197 |
| |
167 | 198 |
| |
168 | 199 |
| |
169 |
| - | |
170 |
| - | |
| 200 | + | |
| 201 | + | |
171 | 202 |
| |
172 | 203 |
| |
173 | 204 |
| |
| |||
209 | 240 |
| |
210 | 241 |
| |
211 | 242 |
| |
| 243 | + | |
212 | 244 |
| |
213 | 245 |
| |
214 | 246 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1629 | 1629 |
| |
1630 | 1630 |
| |
1631 | 1631 |
| |
| 1632 | + | |
1632 | 1633 |
| |
1633 | 1634 |
| |
1634 | 1635 |
| |
|
Lines changed: 16 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
264 | 264 |
| |
265 | 265 |
| |
266 | 266 |
| |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
267 | 272 |
| |
268 | 273 |
| |
269 | 274 |
| |
| |||
292 | 297 |
| |
293 | 298 |
| |
294 | 299 |
| |
| 300 | + | |
295 | 301 |
| |
296 | 302 |
| |
297 | 303 |
| |
298 | 304 |
| |
299 | 305 |
| |
300 | 306 |
| |
301 | 307 |
| |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
302 | 313 |
| |
303 | 314 |
| |
304 | 315 |
| |
| |||
312 | 323 |
| |
313 | 324 |
| |
314 | 325 |
| |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
315 | 331 |
| |
316 | 332 |
| |
317 | 333 |
| |
|
Lines changed: 3 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
14 | 14 |
| |
15 | 15 |
| |
16 | 16 |
| |
17 |
| - | |
| 17 | + | |
| 18 | + | |
18 | 19 |
| |
19 | 20 |
| |
20 | 21 |
| |
| |||
71 | 72 |
| |
72 | 73 |
| |
73 | 74 |
| |
| 75 | + | |
74 | 76 |
| |
75 | 77 |
| |
76 | 78 |
| |
|
Lines changed: 23 additions & 17 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
3287 | 3287 |
| |
3288 | 3288 |
| |
3289 | 3289 |
| |
| 3290 | + | |
3290 | 3291 |
| |
3291 | 3292 |
| |
3292 | 3293 |
| |
| |||
5558 | 5559 |
| |
5559 | 5560 |
| |
5560 | 5561 |
| |
| 5562 | + | |
| 5563 | + | |
| 5564 | + | |
| 5565 | + | |
| 5566 | + | |
| 5567 | + | |
5561 | 5568 |
| |
5562 | 5569 |
| |
5563 | 5570 |
| |
| |||
5592 | 5599 |
| |
5593 | 5600 |
| |
5594 | 5601 |
| |
| 5602 | + | |
| 5603 | + | |
| 5604 | + | |
5595 | 5605 |
| |
5596 | 5606 |
| |
5597 | 5607 |
| |
| |||
5623 | 5633 |
| |
5624 | 5634 |
| |
5625 | 5635 |
| |
| 5636 | + | |
5626 | 5637 |
| |
5627 | 5638 |
| |
5628 | 5639 |
| |
| |||
5696 | 5707 |
| |
5697 | 5708 |
| |
5698 | 5709 |
| |
5699 |
| - | |
5700 |
| - | |
5701 |
| - | |
5702 |
| - | |
5703 |
| - | |
5704 |
| - | |
5705 |
| - | |
5706 |
| - | |
5707 |
| - | |
5708 |
| - | |
5709 |
| - | |
5710 |
| - | |
5711 |
| - | |
5712 |
| - | |
5713 |
| - | |
| 5710 | + | |
| 5711 | + | |
| 5712 | + | |
| 5713 | + | |
| 5714 | + | |
| 5715 | + | |
| 5716 | + | |
| 5717 | + | |
| 5718 | + | |
| 5719 | + | |
| 5720 | + | |
5714 | 5721 |
| |
5715 | 5722 |
| |
5716 |
| - | |
5717 |
| - | |
| 5723 | + | |
5718 | 5724 |
| |
5719 | 5725 |
| |
5720 | 5726 |
| |
|
0 commit comments
Comments
(0)