OLD | NEW |
1 # | 1 # |
2 # Autogenerated by generate-bytecode-expectations. | 2 # Autogenerated by generate-bytecode-expectations. |
3 # | 3 # |
4 | 4 |
5 --- | 5 --- |
6 pool type: mixed | 6 pool type: mixed |
7 execute: yes | 7 execute: yes |
8 wrap: yes | 8 wrap: yes |
9 | 9 |
10 --- | 10 --- |
11 snippet: " | 11 snippet: " |
12 var x = 0; | 12 var x = 0; |
13 label: { | 13 label: { |
14 x = x + 1; | 14 x = x + 1; |
15 break label; | 15 break label; |
16 x = x + 1; | 16 x = x + 1; |
17 } | 17 } |
18 return x; | 18 return x; |
19 " | 19 " |
20 frame size: 2 | 20 frame size: 1 |
21 parameter count: 1 | 21 parameter count: 1 |
22 bytecode array length: 17 | 22 bytecode array length: 15 |
23 bytecodes: [ | 23 bytecodes: [ |
24 /* 30 E> */ B(StackCheck), | 24 /* 30 E> */ B(StackCheck), |
25 /* 42 S> */ B(LdaZero), | 25 /* 42 S> */ B(LdaZero), |
26 /* 42 E> */ B(Star), R(0), | 26 /* 42 E> */ B(Star), R(0), |
27 /* 56 S> */ B(Star), R(1), | 27 /* 56 S> */ B(LdaSmi), U8(1), |
28 B(LdaSmi), U8(1), | 28 B(Add), R(0), |
29 B(Add), R(1), | |
30 /* 58 E> */ B(Star), R(0), | 29 /* 58 E> */ B(Star), R(0), |
31 /* 69 S> */ B(Jump), U8(2), | 30 /* 69 S> */ B(Jump), U8(2), |
32 /* 97 S> */ B(Ldar), R(0), | 31 /* 97 S> */ B(Ldar), R(0), |
33 /* 107 S> */ B(Return), | 32 /* 107 S> */ B(Return), |
34 ] | 33 ] |
35 constant pool: [ | 34 constant pool: [ |
36 ] | 35 ] |
37 handlers: [ | 36 handlers: [ |
38 ] | 37 ] |
39 | 38 |
40 --- | 39 --- |
41 snippet: " | 40 snippet: " |
42 var sum = 0; | 41 var sum = 0; |
43 outer: { | 42 outer: { |
44 for (var x = 0; x < 10; ++x) { | 43 for (var x = 0; x < 10; ++x) { |
45 for (var y = 0; y < 3; ++y) { | 44 for (var y = 0; y < 3; ++y) { |
46 ++sum; | 45 ++sum; |
47 if (x + y == 12) { break outer; } | 46 if (x + y == 12) { break outer; } |
48 } | 47 } |
49 } | 48 } |
50 } | 49 } |
51 return sum; | 50 return sum; |
52 " | 51 " |
53 frame size: 5 | 52 frame size: 5 |
54 parameter count: 1 | 53 parameter count: 1 |
55 bytecode array length: 72 | 54 bytecode array length: 60 |
56 bytecodes: [ | 55 bytecodes: [ |
57 /* 30 E> */ B(StackCheck), | 56 /* 30 E> */ B(StackCheck), |
58 /* 44 S> */ B(LdaZero), | 57 /* 44 S> */ B(LdaZero), |
59 /* 44 E> */ B(Star), R(0), | 58 /* 44 E> */ B(Star), R(0), |
60 /* 71 S> */ B(LdaZero), | 59 /* 71 S> */ B(LdaZero), |
61 /* 71 E> */ B(Star), R(1), | 60 /* 71 E> */ B(Star), R(1), |
62 /* 76 S> */ B(Ldar), R(1), | 61 /* 76 S> */ B(LdaSmi), U8(10), |
63 B(Star), R(3), | 62 /* 76 E> */ B(TestLessThan), R(1), |
64 B(LdaSmi), U8(10), | 63 B(JumpIfFalse), U8(46), |
65 /* 76 E> */ B(TestLessThan), R(3), | |
66 B(JumpIfFalse), U8(54), | |
67 /* 58 E> */ B(StackCheck), | 64 /* 58 E> */ B(StackCheck), |
68 /* 106 S> */ B(LdaZero), | 65 /* 106 S> */ B(LdaZero), |
69 /* 106 E> */ B(Star), R(2), | 66 /* 106 E> */ B(Star), R(2), |
70 /* 111 S> */ B(Ldar), R(2), | 67 /* 111 S> */ B(LdaSmi), U8(3), |
71 B(Star), R(3), | 68 /* 111 E> */ B(TestLessThan), R(2), |
72 B(LdaSmi), U8(3), | 69 B(JumpIfFalse), U8(29), |
73 /* 111 E> */ B(TestLessThan), R(3), | |
74 B(JumpIfFalse), U8(33), | |
75 /* 93 E> */ B(StackCheck), | 70 /* 93 E> */ B(StackCheck), |
76 /* 129 S> */ B(Ldar), R(0), | 71 /* 129 S> */ B(Ldar), R(0), |
77 B(Inc), | 72 B(Inc), |
78 /* 131 E> */ B(Star), R(0), | 73 /* 131 E> */ B(Star), R(0), |
79 /* 142 S> */ B(Ldar), R(1), | 74 /* 142 S> */ B(Ldar), R(2), |
80 B(Star), R(3), | 75 B(Add), R(1), |
81 /* 150 E> */ B(Ldar), R(2), | |
82 B(Add), R(3), | |
83 B(Star), R(4), | 76 B(Star), R(4), |
84 B(LdaSmi), U8(12), | 77 B(LdaSmi), U8(12), |
85 /* 152 E> */ B(TestEqual), R(4), | 78 /* 152 E> */ B(TestEqual), R(4), |
86 B(JumpIfFalse), U8(4), | 79 B(JumpIfFalse), U8(4), |
87 /* 161 S> */ B(Jump), U8(16), | 80 /* 161 S> */ B(Jump), U8(16), |
88 /* 118 S> */ B(Ldar), R(2), | 81 /* 118 S> */ B(Ldar), R(2), |
89 B(Inc), | 82 B(Inc), |
90 /* 118 E> */ B(Star), R(2), | 83 /* 118 E> */ B(Star), R(2), |
91 B(Jump), U8(-39), | 84 B(Jump), U8(-31), |
92 /* 84 S> */ B(Ldar), R(1), | 85 /* 84 S> */ B(Ldar), R(1), |
93 B(Inc), | 86 B(Inc), |
94 /* 84 E> */ B(Star), R(1), | 87 /* 84 E> */ B(Star), R(1), |
95 B(Jump), U8(-60), | 88 B(Jump), U8(-48), |
96 /* 188 S> */ B(Ldar), R(0), | 89 /* 188 S> */ B(Ldar), R(0), |
97 /* 200 S> */ B(Return), | 90 /* 200 S> */ B(Return), |
98 ] | 91 ] |
99 constant pool: [ | 92 constant pool: [ |
100 ] | 93 ] |
101 handlers: [ | 94 handlers: [ |
102 ] | 95 ] |
103 | 96 |
104 --- | 97 --- |
105 snippet: " | 98 snippet: " |
106 outer: { | 99 outer: { |
107 let y = 10; | 100 let y = 10; |
108 function f() { return y; } | 101 function f() { return y; } |
109 break outer; | 102 break outer; |
110 } | 103 } |
111 " | 104 " |
112 frame size: 5 | 105 frame size: 5 |
113 parameter count: 1 | 106 parameter count: 1 |
114 bytecode array length: 51 | 107 bytecode array length: 50 |
115 bytecodes: [ | 108 bytecodes: [ |
116 /* 30 E> */ B(StackCheck), | 109 /* 30 E> */ B(StackCheck), |
117 B(LdaConstant), U8(0), | 110 B(LdaConstant), U8(0), |
118 B(Star), R(3), | 111 B(Star), R(3), |
119 B(Ldar), R(closure), | 112 B(Mov), R(closure), R(4), |
120 B(Star), R(4), | |
121 B(CallRuntime), U16(Runtime::kPushBlockContext), R(3), U8(2), | 113 B(CallRuntime), U16(Runtime::kPushBlockContext), R(3), U8(2), |
122 B(PushContext), R(2), | 114 B(PushContext), R(2), |
123 B(LdaTheHole), | 115 B(LdaTheHole), |
124 B(StaContextSlot), R(context), U8(4), | 116 B(StaContextSlot), R(context), U8(4), |
125 B(CreateClosure), U8(1), U8(0), | 117 B(CreateClosure), U8(1), U8(0), |
126 B(Star), R(0), | 118 B(Star), R(0), |
127 /* 53 S> */ B(LdaSmi), U8(10), | 119 /* 53 S> */ B(LdaSmi), U8(10), |
128 /* 53 E> */ B(StaContextSlot), R(context), U8(4), | 120 /* 53 E> */ B(StaContextSlot), R(context), U8(4), |
129 B(Ldar), R(0), | 121 B(Ldar), R(0), |
130 B(JumpIfNotHole), U8(11), | 122 B(JumpIfNotHole), U8(11), |
(...skipping 22 matching lines...) Expand all Loading... |
153 let y = 2; | 145 let y = 2; |
154 function f() { return x + y; } | 146 function f() { return x + y; } |
155 if (y) break outer; | 147 if (y) break outer; |
156 y = 3; | 148 y = 3; |
157 } | 149 } |
158 } | 150 } |
159 x = 4; | 151 x = 4; |
160 " | 152 " |
161 frame size: 6 | 153 frame size: 6 |
162 parameter count: 1 | 154 parameter count: 1 |
163 bytecode array length: 131 | 155 bytecode array length: 130 |
164 bytecodes: [ | 156 bytecodes: [ |
165 B(CallRuntime), U16(Runtime::kNewFunctionContext), R(closure), U
8(1), | 157 B(CallRuntime), U16(Runtime::kNewFunctionContext), R(closure), U
8(1), |
166 B(PushContext), R(2), | 158 B(PushContext), R(2), |
167 B(LdaTheHole), | 159 B(LdaTheHole), |
168 B(StaContextSlot), R(context), U8(4), | 160 B(StaContextSlot), R(context), U8(4), |
169 /* 30 E> */ B(StackCheck), | 161 /* 30 E> */ B(StackCheck), |
170 /* 42 S> */ B(LdaSmi), U8(1), | 162 /* 42 S> */ B(LdaSmi), U8(1), |
171 /* 42 E> */ B(StaContextSlot), R(context), U8(4), | 163 /* 42 E> */ B(StaContextSlot), R(context), U8(4), |
172 B(LdaConstant), U8(0), | 164 B(LdaConstant), U8(0), |
173 B(Star), R(4), | 165 B(Star), R(4), |
174 B(Ldar), R(closure), | 166 B(Mov), R(closure), R(5), |
175 B(Star), R(5), | |
176 B(CallRuntime), U16(Runtime::kPushBlockContext), R(4), U8(2), | 167 B(CallRuntime), U16(Runtime::kPushBlockContext), R(4), U8(2), |
177 B(PushContext), R(3), | 168 B(PushContext), R(3), |
178 B(LdaTheHole), | 169 B(LdaTheHole), |
179 B(StaContextSlot), R(context), U8(4), | 170 B(StaContextSlot), R(context), U8(4), |
180 B(CreateClosure), U8(1), U8(0), | 171 B(CreateClosure), U8(1), U8(0), |
181 B(Star), R(0), | 172 B(Star), R(0), |
182 /* 76 S> */ B(LdaSmi), U8(2), | 173 /* 76 S> */ B(LdaSmi), U8(2), |
183 /* 76 E> */ B(StaContextSlot), R(context), U8(4), | 174 /* 76 E> */ B(StaContextSlot), R(context), U8(4), |
184 B(Ldar), R(0), | 175 B(Ldar), R(0), |
185 B(JumpIfNotHole), U8(11), | 176 B(JumpIfNotHole), U8(11), |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
220 constant pool: [ | 211 constant pool: [ |
221 InstanceType::FIXED_ARRAY_TYPE, | 212 InstanceType::FIXED_ARRAY_TYPE, |
222 InstanceType::SHARED_FUNCTION_INFO_TYPE, | 213 InstanceType::SHARED_FUNCTION_INFO_TYPE, |
223 InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE, | 214 InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE, |
224 InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE, | 215 InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE, |
225 InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE, | 216 InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE, |
226 ] | 217 ] |
227 handlers: [ | 218 handlers: [ |
228 ] | 219 ] |
229 | 220 |
OLD | NEW |