OLD | NEW |
1 # | 1 # |
2 # Autogenerated by generate-bytecode-expectations. | 2 # Autogenerated by generate-bytecode-expectations. |
3 # | 3 # |
4 | 4 |
5 --- | 5 --- |
6 wrap: yes | 6 wrap: yes |
7 | 7 |
8 --- | 8 --- |
9 snippet: " | 9 snippet: " |
10 var x = 0, y = 1; | 10 var x = 0, y = 1; |
11 return (x = 2, y = 3, x = 4, y = 5); | 11 return (x = 2, y = 3, x = 4, y = 5); |
12 " | 12 " |
13 frame size: 2 | 13 frame size: 3 |
14 parameter count: 1 | 14 parameter count: 1 |
15 bytecode array length: 25 | 15 bytecode array length: 49 |
16 bytecodes: [ | 16 bytecodes: [ |
17 /* 30 E> */ B(StackCheck), | 17 /* 30 E> */ B(StackCheck), |
18 /* 42 S> */ B(LdaZero), | 18 /* 42 S> */ B(LdaConstant), U8(0), |
| 19 B(Star), R(2), |
| 20 B(LdaZero), |
19 B(Star), R(0), | 21 B(Star), R(0), |
20 /* 49 S> */ B(LdaSmi), I8(1), | 22 /* 49 S> */ B(LdaConstant), U8(1), |
| 23 B(Star), R(2), |
| 24 B(LdaSmi), I8(1), |
21 B(Star), R(1), | 25 B(Star), R(1), |
22 /* 52 S> */ B(LdaSmi), I8(2), | 26 /* 52 S> */ B(LdaConstant), U8(0), |
| 27 B(Star), R(2), |
| 28 B(LdaSmi), I8(2), |
23 B(Star), R(0), | 29 B(Star), R(0), |
| 30 B(LdaConstant), U8(1), |
| 31 B(Star), R(2), |
24 B(LdaSmi), I8(3), | 32 B(LdaSmi), I8(3), |
25 B(Star), R(1), | 33 B(Star), R(1), |
| 34 B(LdaConstant), U8(0), |
| 35 B(Star), R(2), |
26 B(LdaSmi), I8(4), | 36 B(LdaSmi), I8(4), |
27 B(Star), R(0), | 37 B(Star), R(0), |
| 38 B(LdaConstant), U8(1), |
| 39 B(Star), R(2), |
28 B(LdaSmi), I8(5), | 40 B(LdaSmi), I8(5), |
29 B(Star), R(1), | 41 B(Star), R(1), |
30 /* 89 S> */ B(Return), | 42 /* 89 S> */ B(Return), |
31 ] | 43 ] |
32 constant pool: [ | 44 constant pool: [ |
| 45 ONE_BYTE_INTERNALIZED_STRING_TYPE ["x"], |
| 46 ONE_BYTE_INTERNALIZED_STRING_TYPE ["y"], |
33 ] | 47 ] |
34 handlers: [ | 48 handlers: [ |
35 ] | 49 ] |
36 | 50 |
37 --- | 51 --- |
38 snippet: " | 52 snippet: " |
39 var x = 55; | 53 var x = 55; |
40 var y = (x = 100); | 54 var y = (x = 100); |
41 return y; | 55 return y; |
42 " | 56 " |
43 frame size: 2 | 57 frame size: 4 |
44 parameter count: 1 | 58 parameter count: 1 |
45 bytecode array length: 13 | 59 bytecode array length: 25 |
46 bytecodes: [ | 60 bytecodes: [ |
47 /* 30 E> */ B(StackCheck), | 61 /* 30 E> */ B(StackCheck), |
48 /* 42 S> */ B(LdaSmi), I8(55), | 62 /* 42 S> */ B(LdaConstant), U8(0), |
| 63 B(Star), R(2), |
| 64 B(LdaSmi), I8(55), |
49 B(Star), R(0), | 65 B(Star), R(0), |
50 /* 57 S> */ B(LdaSmi), I8(100), | 66 /* 57 S> */ B(LdaConstant), U8(1), |
| 67 B(Star), R(2), |
| 68 B(LdaConstant), U8(0), |
| 69 B(Star), R(3), |
| 70 B(LdaSmi), I8(100), |
51 B(Star), R(0), | 71 B(Star), R(0), |
52 B(Star), R(1), | 72 B(Star), R(1), |
53 /* 65 S> */ B(Nop), | 73 /* 65 S> */ B(Nop), |
54 /* 75 S> */ B(Return), | 74 /* 75 S> */ B(Return), |
55 ] | 75 ] |
56 constant pool: [ | 76 constant pool: [ |
| 77 ONE_BYTE_INTERNALIZED_STRING_TYPE ["x"], |
| 78 ONE_BYTE_INTERNALIZED_STRING_TYPE ["y"], |
57 ] | 79 ] |
58 handlers: [ | 80 handlers: [ |
59 ] | 81 ] |
60 | 82 |
61 --- | 83 --- |
62 snippet: " | 84 snippet: " |
63 var x = 55; | 85 var x = 55; |
64 x = x + (x = 100) + (x = 101); | 86 x = x + (x = 100) + (x = 101); |
65 return x; | 87 return x; |
66 " | 88 " |
67 frame size: 2 | 89 frame size: 4 |
68 parameter count: 1 | 90 parameter count: 1 |
69 bytecode array length: 28 | 91 bytecode array length: 44 |
70 bytecodes: [ | 92 bytecodes: [ |
71 /* 30 E> */ B(StackCheck), | 93 /* 30 E> */ B(StackCheck), |
72 /* 42 S> */ B(LdaSmi), I8(55), | 94 /* 42 S> */ B(LdaConstant), U8(0), |
| 95 B(Star), R(1), |
| 96 B(LdaSmi), I8(55), |
73 B(Star), R(0), | 97 B(Star), R(0), |
74 /* 46 S> */ B(LdaSmi), I8(100), | 98 /* 46 S> */ B(LdaConstant), U8(0), |
75 B(Mov), R(0), R(1), | 99 B(Star), R(1), |
| 100 B(LdaConstant), U8(0), |
| 101 B(Star), R(3), |
| 102 B(LdaSmi), I8(100), |
| 103 B(Mov), R(0), R(2), |
76 B(Star), R(0), | 104 B(Star), R(0), |
77 /* 52 E> */ B(Add), R(1), U8(2), | 105 /* 52 E> */ B(Add), R(2), U8(6), |
78 B(Star), R(1), | 106 B(Star), R(2), |
| 107 B(LdaConstant), U8(0), |
| 108 B(Star), R(3), |
79 B(LdaSmi), I8(101), | 109 B(LdaSmi), I8(101), |
80 B(Star), R(0), | 110 B(Star), R(0), |
81 /* 64 E> */ B(Add), R(1), U8(3), | 111 /* 64 E> */ B(Add), R(2), U8(9), |
82 B(Star), R(0), | 112 B(Star), R(0), |
83 /* 77 S> */ B(Nop), | 113 /* 77 S> */ B(Nop), |
84 /* 87 S> */ B(Return), | 114 /* 87 S> */ B(Return), |
85 ] | 115 ] |
86 constant pool: [ | 116 constant pool: [ |
| 117 ONE_BYTE_INTERNALIZED_STRING_TYPE ["x"], |
87 ] | 118 ] |
88 handlers: [ | 119 handlers: [ |
89 ] | 120 ] |
90 | 121 |
91 --- | 122 --- |
92 snippet: " | 123 snippet: " |
93 var x = 55; | 124 var x = 55; |
94 x = (x = 56) - x + (x = 57); | 125 x = (x = 56) - x + (x = 57); |
95 x++; | 126 x++; |
96 return x; | 127 return x; |
97 " | 128 " |
98 frame size: 2 | 129 frame size: 4 |
99 parameter count: 1 | 130 parameter count: 1 |
100 bytecode array length: 29 | 131 bytecode array length: 45 |
101 bytecodes: [ | 132 bytecodes: [ |
102 /* 30 E> */ B(StackCheck), | 133 /* 30 E> */ B(StackCheck), |
103 /* 42 S> */ B(LdaSmi), I8(55), | 134 /* 42 S> */ B(LdaConstant), U8(0), |
| 135 B(Star), R(1), |
| 136 B(LdaSmi), I8(55), |
104 B(Star), R(0), | 137 B(Star), R(0), |
105 /* 46 S> */ B(LdaSmi), I8(56), | 138 /* 46 S> */ B(LdaConstant), U8(0), |
| 139 B(Star), R(1), |
| 140 B(LdaConstant), U8(0), |
| 141 B(Star), R(2), |
| 142 B(LdaSmi), I8(56), |
106 B(Star), R(0), | 143 B(Star), R(0), |
107 /* 59 E> */ B(Sub), R(0), U8(2), | 144 /* 59 E> */ B(Sub), R(0), U8(6), |
108 B(Star), R(1), | 145 B(Star), R(2), |
| 146 B(LdaConstant), U8(0), |
| 147 B(Star), R(3), |
109 B(LdaSmi), I8(57), | 148 B(LdaSmi), I8(57), |
110 B(Star), R(0), | 149 B(Star), R(0), |
111 /* 63 E> */ B(Add), R(1), U8(3), | 150 /* 63 E> */ B(Add), R(2), U8(9), |
112 B(Star), R(0), | 151 B(Star), R(0), |
113 /* 75 S> */ B(Inc), U8(4), | 152 /* 75 S> */ B(Inc), U8(12), |
114 B(Star), R(0), | 153 B(Star), R(0), |
115 /* 80 S> */ B(Nop), | 154 /* 80 S> */ B(Nop), |
116 /* 90 S> */ B(Return), | 155 /* 90 S> */ B(Return), |
117 ] | 156 ] |
118 constant pool: [ | 157 constant pool: [ |
| 158 ONE_BYTE_INTERNALIZED_STRING_TYPE ["x"], |
119 ] | 159 ] |
120 handlers: [ | 160 handlers: [ |
121 ] | 161 ] |
122 | 162 |
123 --- | 163 --- |
124 snippet: " | 164 snippet: " |
125 var x = 55; | 165 var x = 55; |
126 var y = x + (x = 1) + (x = 2) + (x = 3); | 166 var y = x + (x = 1) + (x = 2) + (x = 3); |
127 return y; | 167 return y; |
128 " | 168 " |
129 frame size: 3 | 169 frame size: 5 |
130 parameter count: 1 | 170 parameter count: 1 |
131 bytecode array length: 37 | 171 bytecode array length: 57 |
132 bytecodes: [ | 172 bytecodes: [ |
133 /* 30 E> */ B(StackCheck), | 173 /* 30 E> */ B(StackCheck), |
134 /* 42 S> */ B(LdaSmi), I8(55), | 174 /* 42 S> */ B(LdaConstant), U8(0), |
| 175 B(Star), R(2), |
| 176 B(LdaSmi), I8(55), |
135 B(Star), R(0), | 177 B(Star), R(0), |
136 /* 76 S> */ B(LdaSmi), I8(1), | 178 /* 76 S> */ B(LdaConstant), U8(1), |
137 B(Mov), R(0), R(2), | 179 B(Star), R(2), |
| 180 B(LdaConstant), U8(0), |
| 181 B(Star), R(4), |
| 182 B(LdaSmi), I8(1), |
| 183 B(Mov), R(0), R(3), |
138 B(Star), R(0), | 184 B(Star), R(0), |
139 /* 56 E> */ B(Add), R(2), U8(2), | 185 /* 56 E> */ B(Add), R(3), U8(6), |
140 B(Star), R(2), | 186 B(Star), R(3), |
| 187 B(LdaConstant), U8(0), |
| 188 B(Star), R(4), |
141 B(LdaSmi), I8(2), | 189 B(LdaSmi), I8(2), |
142 B(Star), R(0), | 190 B(Star), R(0), |
143 /* 66 E> */ B(Add), R(2), U8(3), | 191 /* 66 E> */ B(Add), R(3), U8(9), |
144 B(Star), R(2), | 192 B(Star), R(3), |
| 193 B(LdaConstant), U8(0), |
| 194 B(Star), R(4), |
145 B(LdaSmi), I8(3), | 195 B(LdaSmi), I8(3), |
146 B(Star), R(0), | 196 B(Star), R(0), |
147 /* 76 E> */ B(Add), R(2), U8(4), | 197 /* 76 E> */ B(Add), R(3), U8(12), |
148 B(Star), R(1), | 198 B(Star), R(1), |
149 /* 87 S> */ B(Nop), | 199 /* 87 S> */ B(Nop), |
150 /* 97 S> */ B(Return), | 200 /* 97 S> */ B(Return), |
151 ] | 201 ] |
152 constant pool: [ | 202 constant pool: [ |
| 203 ONE_BYTE_INTERNALIZED_STRING_TYPE ["x"], |
| 204 ONE_BYTE_INTERNALIZED_STRING_TYPE ["y"], |
153 ] | 205 ] |
154 handlers: [ | 206 handlers: [ |
155 ] | 207 ] |
156 | 208 |
157 --- | 209 --- |
158 snippet: " | 210 snippet: " |
159 var x = 55; | 211 var x = 55; |
160 var x = x + (x = 1) + (x = 2) + (x = 3); | 212 var x = x + (x = 1) + (x = 2) + (x = 3); |
161 return x; | 213 return x; |
162 " | 214 " |
163 frame size: 2 | 215 frame size: 4 |
164 parameter count: 1 | 216 parameter count: 1 |
165 bytecode array length: 37 | 217 bytecode array length: 57 |
166 bytecodes: [ | 218 bytecodes: [ |
167 /* 30 E> */ B(StackCheck), | 219 /* 30 E> */ B(StackCheck), |
168 /* 42 S> */ B(LdaSmi), I8(55), | 220 /* 42 S> */ B(LdaConstant), U8(0), |
| 221 B(Star), R(1), |
| 222 B(LdaSmi), I8(55), |
169 B(Star), R(0), | 223 B(Star), R(0), |
170 /* 76 S> */ B(LdaSmi), I8(1), | 224 /* 76 S> */ B(LdaConstant), U8(0), |
171 B(Mov), R(0), R(1), | 225 B(Star), R(1), |
| 226 B(LdaConstant), U8(0), |
| 227 B(Star), R(3), |
| 228 B(LdaSmi), I8(1), |
| 229 B(Mov), R(0), R(2), |
172 B(Star), R(0), | 230 B(Star), R(0), |
173 /* 56 E> */ B(Add), R(1), U8(2), | 231 /* 56 E> */ B(Add), R(2), U8(6), |
174 B(Star), R(1), | 232 B(Star), R(2), |
| 233 B(LdaConstant), U8(0), |
| 234 B(Star), R(3), |
175 B(LdaSmi), I8(2), | 235 B(LdaSmi), I8(2), |
176 B(Star), R(0), | 236 B(Star), R(0), |
177 /* 66 E> */ B(Add), R(1), U8(3), | 237 /* 66 E> */ B(Add), R(2), U8(9), |
178 B(Star), R(1), | 238 B(Star), R(2), |
| 239 B(LdaConstant), U8(0), |
| 240 B(Star), R(3), |
179 B(LdaSmi), I8(3), | 241 B(LdaSmi), I8(3), |
180 B(Star), R(0), | 242 B(Star), R(0), |
181 /* 76 E> */ B(Add), R(1), U8(4), | 243 /* 76 E> */ B(Add), R(2), U8(12), |
182 B(Star), R(0), | 244 B(Star), R(0), |
183 /* 87 S> */ B(Nop), | 245 /* 87 S> */ B(Nop), |
184 /* 97 S> */ B(Return), | 246 /* 97 S> */ B(Return), |
185 ] | 247 ] |
186 constant pool: [ | 248 constant pool: [ |
| 249 ONE_BYTE_INTERNALIZED_STRING_TYPE ["x"], |
187 ] | 250 ] |
188 handlers: [ | 251 handlers: [ |
189 ] | 252 ] |
190 | 253 |
191 --- | 254 --- |
192 snippet: " | 255 snippet: " |
193 var x = 10, y = 20; | 256 var x = 10, y = 20; |
194 return x + (x = 1) + (x + 1) * (y = 2) + (y = 3) + (x = 4) + (y = 5) + y; | 257 return x + (x = 1) + (x + 1) * (y = 2) + (y = 3) + (x = 4) + (y = 5) + y; |
195 " | 258 " |
196 frame size: 4 | 259 frame size: 5 |
197 parameter count: 1 | 260 parameter count: 1 |
198 bytecode array length: 72 | 261 bytecode array length: 100 |
199 bytecodes: [ | 262 bytecodes: [ |
200 /* 30 E> */ B(StackCheck), | 263 /* 30 E> */ B(StackCheck), |
201 /* 42 S> */ B(LdaSmi), I8(10), | 264 /* 42 S> */ B(LdaConstant), U8(0), |
| 265 B(Star), R(2), |
| 266 B(LdaSmi), I8(10), |
202 B(Star), R(0), | 267 B(Star), R(0), |
203 /* 50 S> */ B(LdaSmi), I8(20), | 268 /* 50 S> */ B(LdaConstant), U8(1), |
| 269 B(Star), R(2), |
| 270 B(LdaSmi), I8(20), |
204 B(Star), R(1), | 271 B(Star), R(1), |
205 /* 54 S> */ B(LdaSmi), I8(1), | 272 /* 54 S> */ B(LdaConstant), U8(0), |
| 273 B(Star), R(3), |
| 274 B(LdaSmi), I8(1), |
206 B(Mov), R(0), R(2), | 275 B(Mov), R(0), R(2), |
207 B(Star), R(0), | 276 B(Star), R(0), |
208 /* 63 E> */ B(Add), R(2), U8(2), | 277 /* 63 E> */ B(Add), R(2), U8(8), |
209 B(Star), R(2), | 278 B(Star), R(2), |
210 /* 78 E> */ B(AddSmi), I8(1), R(0), U8(3), | 279 /* 78 E> */ B(AddSmi), I8(1), R(0), U8(9), |
211 B(Star), R(3), | 280 B(Star), R(3), |
| 281 B(LdaConstant), U8(1), |
| 282 B(Star), R(4), |
212 B(LdaSmi), I8(2), | 283 B(LdaSmi), I8(2), |
213 B(Star), R(1), | 284 B(Star), R(1), |
214 /* 83 E> */ B(Mul), R(3), U8(4), | 285 /* 83 E> */ B(Mul), R(3), U8(12), |
215 /* 73 E> */ B(Add), R(2), U8(5), | 286 /* 73 E> */ B(Add), R(2), U8(13), |
216 B(Star), R(2), | 287 B(Star), R(2), |
| 288 B(LdaConstant), U8(1), |
| 289 B(Star), R(3), |
217 B(LdaSmi), I8(3), | 290 B(LdaSmi), I8(3), |
218 B(Star), R(1), | 291 B(Star), R(1), |
219 /* 93 E> */ B(Add), R(2), U8(6), | 292 /* 93 E> */ B(Add), R(2), U8(16), |
220 B(Star), R(2), | 293 B(Star), R(2), |
| 294 B(LdaConstant), U8(0), |
| 295 B(Star), R(3), |
221 B(LdaSmi), I8(4), | 296 B(LdaSmi), I8(4), |
222 B(Star), R(0), | 297 B(Star), R(0), |
223 /* 103 E> */ B(Add), R(2), U8(7), | 298 /* 103 E> */ B(Add), R(2), U8(19), |
224 B(Star), R(2), | 299 B(Star), R(2), |
| 300 B(LdaConstant), U8(1), |
| 301 B(Star), R(3), |
225 B(LdaSmi), I8(5), | 302 B(LdaSmi), I8(5), |
226 B(Star), R(1), | 303 B(Star), R(1), |
227 /* 113 E> */ B(Add), R(2), U8(8), | 304 /* 113 E> */ B(Add), R(2), U8(22), |
228 B(Star), R(2), | 305 B(Star), R(2), |
229 B(Ldar), R(1), | 306 B(Ldar), R(1), |
230 /* 123 E> */ B(Add), R(2), U8(9), | 307 /* 123 E> */ B(Add), R(2), U8(23), |
231 /* 128 S> */ B(Return), | 308 /* 128 S> */ B(Return), |
232 ] | 309 ] |
233 constant pool: [ | 310 constant pool: [ |
| 311 ONE_BYTE_INTERNALIZED_STRING_TYPE ["x"], |
| 312 ONE_BYTE_INTERNALIZED_STRING_TYPE ["y"], |
234 ] | 313 ] |
235 handlers: [ | 314 handlers: [ |
236 ] | 315 ] |
237 | 316 |
238 --- | 317 --- |
239 snippet: " | 318 snippet: " |
240 var x = 17; | 319 var x = 17; |
241 return 1 + x + (x++) + (++x); | 320 return 1 + x + (x++) + (++x); |
242 " | 321 " |
243 frame size: 3 | 322 frame size: 3 |
244 parameter count: 1 | 323 parameter count: 1 |
245 bytecode array length: 43 | 324 bytecode array length: 47 |
246 bytecodes: [ | 325 bytecodes: [ |
247 /* 30 E> */ B(StackCheck), | 326 /* 30 E> */ B(StackCheck), |
248 /* 42 S> */ B(LdaSmi), I8(17), | 327 /* 42 S> */ B(LdaConstant), U8(0), |
| 328 B(Star), R(1), |
| 329 B(LdaSmi), I8(17), |
249 B(Star), R(0), | 330 B(Star), R(0), |
250 /* 46 S> */ B(LdaSmi), I8(1), | 331 /* 46 S> */ B(LdaSmi), I8(1), |
251 B(Star), R(1), | 332 B(Star), R(1), |
252 B(Ldar), R(0), | 333 B(Ldar), R(0), |
253 /* 55 E> */ B(Add), R(1), U8(2), | 334 /* 55 E> */ B(Add), R(1), U8(4), |
254 B(Star), R(1), | 335 B(Star), R(1), |
255 B(Ldar), R(0), | 336 B(Ldar), R(0), |
256 B(ToNumber), R(2), | 337 B(ToNumber), R(2), |
257 B(Ldar), R(2), | 338 B(Ldar), R(2), |
258 B(Inc), U8(3), | 339 B(Inc), U8(5), |
259 B(Star), R(0), | 340 B(Star), R(0), |
260 B(Ldar), R(2), | 341 B(Ldar), R(2), |
261 /* 59 E> */ B(Add), R(1), U8(4), | 342 /* 59 E> */ B(Add), R(1), U8(6), |
262 B(Star), R(1), | 343 B(Star), R(1), |
263 B(Ldar), R(0), | 344 B(Ldar), R(0), |
264 B(Inc), U8(5), | 345 B(Inc), U8(7), |
265 B(Star), R(0), | 346 B(Star), R(0), |
266 /* 67 E> */ B(Add), R(1), U8(6), | 347 /* 67 E> */ B(Add), R(1), U8(8), |
267 /* 76 S> */ B(Return), | 348 /* 76 S> */ B(Return), |
268 ] | 349 ] |
269 constant pool: [ | 350 constant pool: [ |
| 351 ONE_BYTE_INTERNALIZED_STRING_TYPE ["x"], |
270 ] | 352 ] |
271 handlers: [ | 353 handlers: [ |
272 ] | 354 ] |
273 | 355 |
OLD | NEW |