- Notifications
You must be signed in to change notification settings - Fork5.1k
Commitfd726b8
committed
test_json_parser: Speed up 002_inline.pl
Some macOS machines are having trouble with 002_inline, which executesthe JSON parser test executables hundreds of times in a nested loop.Both developer machines and buildfarm critters have shown excessive testdurations, upwards of 20 seconds.Push the innermost loop of 002_inline, which iterates through differingchunk sizes, down into the test executable. (I'd eventually like to pushall of the JSON unit tests down into C, but this is an easy win in theshort term.) Testers have reported a speedup between 4-9x.Reported-by: Robert Haas <robertmhaas@gmail.com>Suggested-by: Andres Freund <andres@anarazel.de>Tested-by: Andrew Dunstan <andrew@dunslane.net>Tested-by: Tom Lane <tgl@sss.pgh.pa.us>Tested-by: Robert Haas <robertmhaas@gmail.com>Discussion:https://postgr.es/m/CA%2BTgmobKoG%2BgKzH9qB7uE4MFo-z1hn7UngqAe9b0UqNbn3_XGQ%40mail.gmail.comBackpatch-through: 171 parent3e908fb commitfd726b8
File tree
3 files changed
+106
-57
lines changed- src/test/modules/test_json_parser
- t
3 files changed
+106
-57
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
6 | 6 |
| |
7 | 7 |
| |
8 | 8 |
| |
9 |
| - | |
10 |
| - | |
11 |
| - | |
12 |
| - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
13 | 15 |
| |
14 | 16 |
| |
15 | 17 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
33 | 33 |
| |
34 | 34 |
| |
35 | 35 |
| |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
36 | 50 |
| |
37 | 51 |
| |
38 |
| - | |
39 |
| - | |
40 | 52 |
| |
41 | 53 |
| |
42 |
| - | |
| 54 | + | |
43 | 55 |
| |
44 |
| - | |
| 56 | + | |
45 | 57 |
| |
46 | 58 |
| |
47 | 59 |
| |
48 | 60 |
| |
49 |
| - | |
| 61 | + | |
50 | 62 |
| |
51 |
| - | |
| 63 | + | |
52 | 64 |
| |
| 65 | + | |
| 66 | + | |
53 | 67 |
| |
54 | 68 |
| |
55 | 69 |
| |
|
Lines changed: 80 additions & 47 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
12 | 12 |
| |
13 | 13 |
| |
14 | 14 |
| |
| 15 | + | |
15 | 16 |
| |
16 | 17 |
| |
17 | 18 |
| |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
18 | 23 |
| |
19 | 24 |
| |
20 | 25 |
| |
| |||
88 | 93 |
| |
89 | 94 |
| |
90 | 95 |
| |
| 96 | + | |
91 | 97 |
| |
92 |
| - | |
93 | 98 |
| |
94 | 99 |
| |
95 | 100 |
| |
| |||
102 | 107 |
| |
103 | 108 |
| |
104 | 109 |
| |
105 |
| - | |
| 110 | + | |
106 | 111 |
| |
107 | 112 |
| |
108 | 113 |
| |
109 |
| - | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
110 | 118 |
| |
111 | 119 |
| |
112 | 120 |
| |
| |||
135 | 143 |
| |
136 | 144 |
| |
137 | 145 |
| |
138 |
| - | |
139 |
| - | |
140 | 146 |
| |
141 | 147 |
| |
142 | 148 |
| |
| |||
145 | 151 |
| |
146 | 152 |
| |
147 | 153 |
| |
148 |
| - | |
149 |
| - | |
150 |
| - | |
| 154 | + | |
151 | 155 |
| |
152 |
| - | |
153 |
| - | |
154 |
| - | |
155 |
| - | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
156 | 163 |
| |
157 |
| - | |
158 |
| - | |
159 |
| - | |
| 164 | + | |
| 165 | + | |
160 | 166 |
| |
161 |
| - | |
| 167 | + | |
| 168 | + | |
162 | 169 |
| |
163 |
| - | |
164 |
| - | |
165 |
| - | |
166 |
| - | |
167 |
| - | |
168 |
| - | |
169 |
| - | |
170 |
| - | |
| 170 | + | |
171 | 171 |
| |
172 |
| - | |
173 |
| - | |
174 |
| - | |
175 |
| - | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
176 | 191 |
| |
177 |
| - | |
178 |
| - | |
179 |
| - | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
180 | 202 |
| |
181 |
| - | |
182 |
| - | |
183 |
| - | |
184 |
| - | |
185 |
| - | |
186 |
| - | |
187 |
| - | |
188 |
| - | |
| 203 | + | |
189 | 204 |
| |
190 |
| - | |
191 |
| - | |
192 |
| - | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
193 | 217 |
| |
194 |
| - | |
195 |
| - | |
196 |
| - | |
197 | 218 |
| |
198 |
| - | |
199 | 219 |
| |
200 | 220 |
| |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
201 | 235 |
| |
202 |
| - | |
203 | 236 |
| |
204 | 237 |
| |
205 | 238 |
| |
|
0 commit comments
Comments
(0)