| Index: test/cctest/interpreter/bytecode_expectations/Generators.golden
|
| diff --git a/test/cctest/interpreter/bytecode_expectations/Generators.golden b/test/cctest/interpreter/bytecode_expectations/Generators.golden
|
| index 580cc98b72519687e2f3118751ff959e39652e3a..424189d719362a5fdff08944787032c8e4198535 100644
|
| --- a/test/cctest/interpreter/bytecode_expectations/Generators.golden
|
| +++ b/test/cctest/interpreter/bytecode_expectations/Generators.golden
|
| @@ -13,17 +13,17 @@ ignition generators: yes
|
| snippet: "
|
| function* f() { }
|
| "
|
| -frame size: 11
|
| +frame size: 10
|
| parameter count: 1
|
| -bytecode array length: 201
|
| +bytecode array length: 193
|
| bytecodes: [
|
| B(Ldar), R(new_target),
|
| - B(JumpIfUndefined), U8(15),
|
| - B(CallRuntime), U16(Runtime::kResumeIgnitionGenerator), R(new_target), U8(1),
|
| + B(JumpIfUndefined), U8(12),
|
| + B(ResumeGenerator), R(new_target),
|
| B(Star), R(1),
|
| B(LdaZero),
|
| B(TestEqualStrict), R(1),
|
| - B(JumpIfTrue), U8(54),
|
| + B(JumpIfTrue), U8(49),
|
| B(Illegal),
|
| B(CallRuntime), U16(Runtime::kNewFunctionContext), R(closure), U8(1),
|
| B(PushContext), R(0),
|
| @@ -41,32 +41,31 @@ bytecodes: [
|
| B(LdaContextSlot), R(context), U8(5),
|
| B(Star), R(5),
|
| B(LdaZero),
|
| - B(Star), R(6),
|
| - B(CallRuntime), U16(Runtime::kSuspendIgnitionGenerator), R(5), U8(2),
|
| + B(SuspendGenerator), R(5),
|
| B(Ldar), R(4),
|
| B(Return),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetInput), R(5), U8(1),
|
| - B(Star), R(7),
|
| + B(Star), R(6),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetResumeMode), R(5), U8(1),
|
| - B(Star), R(8),
|
| + B(Star), R(7),
|
| B(LdaZero),
|
| - B(TestEqualStrict), R(8),
|
| + B(TestEqualStrict), R(7),
|
| B(JumpIfTrue), U8(31),
|
| B(LdaSmi), U8(2),
|
| - B(TestEqualStrict), R(8),
|
| + B(TestEqualStrict), R(7),
|
| B(JumpIfTrue), U8(22),
|
| B(Jump), U8(2),
|
| - B(Mov), R(7), R(9),
|
| + B(Mov), R(6), R(8),
|
| B(LdaTrue),
|
| - B(Star), R(10),
|
| - B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(9), U8(2),
|
| + B(Star), R(9),
|
| + B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(8), U8(2),
|
| B(Star), R(2),
|
| B(LdaZero),
|
| B(Star), R(1),
|
| B(Jump), U8(38),
|
| - B(Ldar), R(7),
|
| + B(Ldar), R(6),
|
| B(Throw),
|
| - B(Ldar), R(7),
|
| + B(Ldar), R(6),
|
| B(LdaUndefined),
|
| B(Star), R(4),
|
| B(LdaTrue),
|
| @@ -110,27 +109,27 @@ bytecodes: [
|
| constant pool: [
|
| ]
|
| handlers: [
|
| - [33, 137, 143],
|
| + [30, 129, 135],
|
| ]
|
|
|
| ---
|
| snippet: "
|
| function* f() { yield 42 }
|
| "
|
| -frame size: 11
|
| +frame size: 10
|
| parameter count: 1
|
| -bytecode array length: 298
|
| +bytecode array length: 285
|
| bytecodes: [
|
| B(Ldar), R(new_target),
|
| - B(JumpIfUndefined), U8(21),
|
| - B(CallRuntime), U16(Runtime::kResumeIgnitionGenerator), R(new_target), U8(1),
|
| + B(JumpIfUndefined), U8(18),
|
| + B(ResumeGenerator), R(new_target),
|
| B(Star), R(1),
|
| B(LdaZero),
|
| B(TestEqualStrict), R(1),
|
| - B(JumpIfTrue), U8(60),
|
| + B(JumpIfTrue), U8(55),
|
| B(LdaSmi), U8(1),
|
| B(TestEqualStrict), R(1),
|
| - B(JumpIfTrueConstant), U8(0),
|
| + B(JumpIfTrue), U8(125),
|
| B(Illegal),
|
| B(CallRuntime), U16(Runtime::kNewFunctionContext), R(closure), U8(1),
|
| B(PushContext), R(0),
|
| @@ -148,32 +147,31 @@ bytecodes: [
|
| B(LdaContextSlot), R(context), U8(5),
|
| B(Star), R(5),
|
| B(LdaZero),
|
| - B(Star), R(6),
|
| - B(CallRuntime), U16(Runtime::kSuspendIgnitionGenerator), R(5), U8(2),
|
| + B(SuspendGenerator), R(5),
|
| B(Ldar), R(4),
|
| B(Return),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetInput), R(5), U8(1),
|
| - B(Star), R(7),
|
| + B(Star), R(6),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetResumeMode), R(5), U8(1),
|
| - B(Star), R(8),
|
| + B(Star), R(7),
|
| B(LdaZero),
|
| - B(TestEqualStrict), R(8),
|
| + B(TestEqualStrict), R(7),
|
| B(JumpIfTrue), U8(31),
|
| B(LdaSmi), U8(2),
|
| - B(TestEqualStrict), R(8),
|
| + B(TestEqualStrict), R(7),
|
| B(JumpIfTrue), U8(22),
|
| B(Jump), U8(2),
|
| - B(Mov), R(7), R(9),
|
| + B(Mov), R(6), R(8),
|
| B(LdaTrue),
|
| - B(Star), R(10),
|
| - B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(9), U8(2),
|
| + B(Star), R(9),
|
| + B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(8), U8(2),
|
| B(Star), R(2),
|
| B(LdaZero),
|
| B(Star), R(1),
|
| - B(Jump), U8(120),
|
| - B(Ldar), R(7),
|
| + B(Jump), U8(115),
|
| + B(Ldar), R(6),
|
| B(Throw),
|
| - B(Ldar), R(7),
|
| + B(Ldar), R(6),
|
| B(LdaSmi), U8(42),
|
| B(Star), R(4),
|
| B(LdaFalse),
|
| @@ -183,32 +181,31 @@ bytecodes: [
|
| B(LdaContextSlot), R(context), U8(5),
|
| B(Star), R(4),
|
| B(LdaSmi), U8(1),
|
| - B(Star), R(5),
|
| - B(CallRuntime), U16(Runtime::kSuspendIgnitionGenerator), R(4), U8(2),
|
| + B(SuspendGenerator), R(4),
|
| B(Ldar), R(6),
|
| B(Return),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetInput), R(4), U8(1),
|
| - B(Star), R(7),
|
| + B(Star), R(5),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetResumeMode), R(4), U8(1),
|
| - B(Star), R(8),
|
| + B(Star), R(7),
|
| B(LdaZero),
|
| - B(TestEqualStrict), R(8),
|
| + B(TestEqualStrict), R(7),
|
| B(JumpIfTrue), U8(32),
|
| B(LdaSmi), U8(2),
|
| - B(TestEqualStrict), R(8),
|
| + B(TestEqualStrict), R(7),
|
| B(JumpIfTrue), U8(23),
|
| B(Jump), U8(2),
|
| - B(Mov), R(7), R(9),
|
| + B(Mov), R(5), R(8),
|
| B(LdaTrue),
|
| - B(Star), R(10),
|
| - B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(9), U8(2),
|
| + B(Star), R(9),
|
| + B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(8), U8(2),
|
| B(Star), R(2),
|
| B(LdaSmi), U8(1),
|
| B(Star), R(1),
|
| B(Jump), U8(38),
|
| - B(Ldar), R(7),
|
| + B(Ldar), R(5),
|
| B(Throw),
|
| - B(Ldar), R(7),
|
| + B(Ldar), R(5),
|
| B(LdaUndefined),
|
| B(Star), R(4),
|
| B(LdaTrue),
|
| @@ -255,27 +252,26 @@ bytecodes: [
|
| B(Return),
|
| ]
|
| constant pool: [
|
| - kInstanceTypeDontCare,
|
| ]
|
| handlers: [
|
| - [39, 225, 231],
|
| + [36, 212, 218],
|
| ]
|
|
|
| ---
|
| snippet: "
|
| function* f() { for (let x of [42]) yield x }
|
| "
|
| -frame size: 17
|
| +frame size: 16
|
| parameter count: 1
|
| -bytecode array length: 786
|
| +bytecode array length: 773
|
| bytecodes: [
|
| B(Ldar), R(new_target),
|
| - B(JumpIfUndefined), U8(21),
|
| - B(CallRuntime), U16(Runtime::kResumeIgnitionGenerator), R(new_target), U8(1),
|
| + B(JumpIfUndefined), U8(18),
|
| + B(ResumeGenerator), R(new_target),
|
| B(Star), R(3),
|
| B(LdaZero),
|
| B(TestEqualStrict), R(3),
|
| - B(JumpIfTrue), U8(60),
|
| + B(JumpIfTrue), U8(55),
|
| B(LdaSmi), U8(1),
|
| B(TestEqualStrict), R(3),
|
| B(JumpIfTrueConstant), U8(8),
|
| @@ -296,32 +292,31 @@ bytecodes: [
|
| B(LdaContextSlot), R(context), U8(5),
|
| B(Star), R(7),
|
| B(LdaZero),
|
| - B(Star), R(8),
|
| - B(CallRuntime), U16(Runtime::kSuspendIgnitionGenerator), R(7), U8(2),
|
| + B(SuspendGenerator), R(7),
|
| B(Ldar), R(6),
|
| B(Return),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetInput), R(7), U8(1),
|
| - B(Star), R(9),
|
| + B(Star), R(8),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetResumeMode), R(7), U8(1),
|
| - B(Star), R(10),
|
| + B(Star), R(9),
|
| B(LdaZero),
|
| - B(TestEqualStrict), R(10),
|
| + B(TestEqualStrict), R(9),
|
| B(JumpIfTrue), U8(31),
|
| B(LdaSmi), U8(2),
|
| - B(TestEqualStrict), R(10),
|
| + B(TestEqualStrict), R(9),
|
| B(JumpIfTrue), U8(22),
|
| B(Jump), U8(2),
|
| - B(Mov), R(9), R(11),
|
| + B(Mov), R(8), R(10),
|
| B(LdaTrue),
|
| - B(Star), R(12),
|
| - B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(11), U8(2),
|
| + B(Star), R(11),
|
| + B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(10), U8(2),
|
| B(Star), R(4),
|
| B(LdaZero),
|
| B(Star), R(3),
|
| B(JumpConstant), U8(16),
|
| - B(Ldar), R(9),
|
| + B(Ldar), R(8),
|
| B(Throw),
|
| - B(Ldar), R(9),
|
| + B(Ldar), R(8),
|
| B(LdaConstant), U8(0),
|
| B(Star), R(6),
|
| B(Ldar), R(closure),
|
| @@ -391,25 +386,24 @@ bytecodes: [
|
| B(LdaContextSlot), R(1), U8(5),
|
| B(Star), R(10),
|
| B(LdaSmi), U8(1),
|
| - B(Star), R(11),
|
| - B(CallRuntime), U16(Runtime::kSuspendIgnitionGenerator), R(10), U8(2),
|
| + B(SuspendGenerator), R(10),
|
| B(Ldar), R(12),
|
| B(Return),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetInput), R(10), U8(1),
|
| - B(Star), R(13),
|
| + B(Star), R(11),
|
| B(CallRuntime), U16(Runtime::kGeneratorGetResumeMode), R(10), U8(1),
|
| - B(Star), R(14),
|
| + B(Star), R(13),
|
| B(LdaZero),
|
| - B(TestEqualStrict), R(14),
|
| + B(TestEqualStrict), R(13),
|
| B(JumpIfTrue), U8(45),
|
| B(LdaSmi), U8(2),
|
| - B(TestEqualStrict), R(14),
|
| + B(TestEqualStrict), R(13),
|
| B(JumpIfTrue), U8(36),
|
| B(Jump), U8(2),
|
| - B(Mov), R(13), R(15),
|
| + B(Mov), R(11), R(14),
|
| B(LdaTrue),
|
| - B(Star), R(16),
|
| - B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(15), U8(2),
|
| + B(Star), R(15),
|
| + B(CallRuntime), U16(Runtime::kCreateIterResultObject), R(14), U8(2),
|
| B(PopContext), R(2),
|
| B(PopContext), R(2),
|
| B(PopContext), R(2),
|
| @@ -421,13 +415,13 @@ bytecodes: [
|
| B(LdaZero),
|
| B(Star), R(6),
|
| B(Jump), U8(78),
|
| - B(Ldar), R(13),
|
| + B(Ldar), R(11),
|
| B(Throw),
|
| - B(Ldar), R(13),
|
| + B(Ldar), R(11),
|
| B(PopContext), R(2),
|
| B(LdaZero),
|
| B(StaContextSlot), R(1), U8(9),
|
| - B(Wide), B(Jump), U16(-210),
|
| + B(Wide), B(Jump), U16(-205),
|
| B(Jump), U8(49),
|
| B(Star), R(11),
|
| B(LdaConstant), U8(10),
|
| @@ -621,9 +615,9 @@ constant pool: [
|
| kInstanceTypeDontCare,
|
| ]
|
| handlers: [
|
| - [39, 704, 710],
|
| - [154, 440, 446],
|
| - [157, 391, 393],
|
| - [548, 563, 565],
|
| + [36, 691, 697],
|
| + [146, 427, 433],
|
| + [149, 378, 380],
|
| + [535, 550, 552],
|
| ]
|
|
|
|
|