v8/test/cctest/interpreter/bytecode_expectations/ForIn.golden
Santiago Aboy Solanes b8d8ab4132 [interpreter] Move IterationBody StackChecks to end of loops
This CL is a step towards making StackChecks implicit. In a follow-up CL
said StackChecks will become implicit within JumpLoops.

Cq-Include-Trybots: luci.chromium.try:linux-rel
Bug: v8:10149, v8:9960
Change-Id: I5ae247be3f7a58ccdf86398cace30724715767a8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2062391
Commit-Queue: Santiago Aboy Solanes <solanes@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#66668}
2020-03-11 18:12:09 +00:00

233 lines
5.8 KiB
Plaintext

#
# Autogenerated by generate-bytecode-expectations.
#
---
wrap: yes
---
snippet: "
for (var p in null) {}
"
frame size: 2
parameter count: 1
bytecode array length: 2
bytecodes: [
B(LdaUndefined),
/* 57 S> */ B(Return),
]
constant pool: [
]
handlers: [
]
---
snippet: "
for (var p in undefined) {}
"
frame size: 2
parameter count: 1
bytecode array length: 2
bytecodes: [
B(LdaUndefined),
/* 62 S> */ B(Return),
]
constant pool: [
]
handlers: [
]
---
snippet: "
for (var p in undefined) {}
"
frame size: 2
parameter count: 1
bytecode array length: 2
bytecodes: [
B(LdaUndefined),
/* 62 S> */ B(Return),
]
constant pool: [
]
handlers: [
]
---
snippet: "
var x = 'potatoes';
for (var p in x) { return p; }
"
frame size: 8
parameter count: 1
bytecode array length: 43
bytecodes: [
/* 42 S> */ B(LdaConstant), U8(0),
B(Star), R(0),
/* 68 S> */ B(JumpIfUndefinedOrNull), U8(37),
B(ToObject), R(3),
B(ForInEnumerate), R(3),
B(ForInPrepare), R(4), U8(0),
B(LdaZero),
B(Star), R(7),
/* 63 S> */ B(ForInContinue), R(7), R(6),
B(JumpIfFalse), U8(22),
B(ForInNext), R(3), R(7), R(4), U8(0),
B(JumpIfUndefined), U8(7),
B(Star), R(2),
/* 63 S> */ B(Star), R(1),
/* 82 S> */ B(Return),
B(ForInStep), R(7),
B(Star), R(7),
/* 54 E> */ B(StackCheck),
B(JumpLoop), U8(22), I8(0),
B(LdaUndefined),
/* 85 S> */ B(Return),
]
constant pool: [
ONE_BYTE_INTERNALIZED_STRING_TYPE ["potatoes"],
]
handlers: [
]
---
snippet: "
var x = 0;
for (var p in [1,2,3]) { x += p; }
"
frame size: 9
parameter count: 1
bytecode array length: 55
bytecodes: [
/* 42 S> */ B(LdaZero),
B(Star), R(0),
/* 59 S> */ B(CreateArrayLiteral), U8(0), U8(1), U8(37),
B(JumpIfUndefinedOrNull), U8(46),
B(ToObject), R(3),
B(ForInEnumerate), R(3),
B(ForInPrepare), R(4), U8(0),
B(LdaZero),
B(Star), R(7),
/* 54 S> */ B(ForInContinue), R(7), R(6),
B(JumpIfFalse), U8(31),
B(ForInNext), R(3), R(7), R(4), U8(0),
B(JumpIfUndefined), U8(16),
B(Star), R(2),
/* 54 S> */ B(Star), R(1),
/* 70 S> */ B(Ldar), R(2),
/* 75 E> */ B(Add), R(0), U8(2),
B(Mov), R(0), R(8),
B(Star), R(0),
/* 72 E> */ B(ForInStep), R(7),
B(Star), R(7),
/* 45 E> */ B(StackCheck),
B(JumpLoop), U8(31), I8(0),
B(LdaUndefined),
/* 80 S> */ B(Return),
]
constant pool: [
ARRAY_BOILERPLATE_DESCRIPTION_TYPE,
]
handlers: [
]
---
snippet: "
var x = { 'a': 1, 'b': 2 };
for (x['a'] in [10, 20, 30]) {
if (x['a'] == 10) continue;
if (x['a'] == 20) break;
}
"
frame size: 7
parameter count: 1
bytecode array length: 82
bytecodes: [
/* 42 S> */ B(CreateObjectLiteral), U8(0), U8(0), U8(41),
B(Star), R(0),
/* 77 S> */ B(CreateArrayLiteral), U8(1), U8(2), U8(37),
B(JumpIfUndefinedOrNull), U8(70),
B(ToObject), R(1),
B(ForInEnumerate), R(1),
B(ForInPrepare), R(2), U8(1),
B(LdaZero),
B(Star), R(5),
/* 68 S> */ B(ForInContinue), R(5), R(4),
B(JumpIfFalse), U8(55),
B(ForInNext), R(1), R(5), R(2), U8(1),
B(JumpIfUndefined), U8(40),
B(Star), R(6),
B(Ldar), R(6),
/* 68 E> */ B(StaNamedProperty), R(0), U8(2), U8(3),
/* 100 S> */ B(LdaNamedProperty), R(0), U8(2), U8(5),
B(Star), R(6),
B(LdaSmi), I8(10),
/* 106 E> */ B(TestEqual), R(6), U8(7),
B(JumpIfFalse), U8(4),
/* 113 S> */ B(Jump), U8(17),
/* 130 S> */ B(LdaNamedProperty), R(0), U8(2), U8(5),
B(Star), R(6),
B(LdaSmi), I8(20),
/* 136 E> */ B(TestEqual), R(6), U8(8),
B(JumpIfFalse), U8(4),
/* 143 S> */ B(Jump), U8(10),
B(ForInStep), R(5),
B(Star), R(5),
/* 62 E> */ B(StackCheck),
B(JumpLoop), U8(55), I8(0),
B(LdaUndefined),
/* 152 S> */ B(Return),
]
constant pool: [
OBJECT_BOILERPLATE_DESCRIPTION_TYPE,
ARRAY_BOILERPLATE_DESCRIPTION_TYPE,
ONE_BYTE_INTERNALIZED_STRING_TYPE ["a"],
]
handlers: [
]
---
snippet: "
var x = [ 10, 11, 12 ] ;
for (x[0] in [1,2,3]) { return x[3]; }
"
frame size: 9
parameter count: 1
bytecode array length: 61
bytecodes: [
/* 42 S> */ B(CreateArrayLiteral), U8(0), U8(0), U8(37),
B(Star), R(0),
/* 72 S> */ B(CreateArrayLiteral), U8(1), U8(2), U8(37),
B(JumpIfUndefinedOrNull), U8(49),
B(ToObject), R(1),
B(ForInEnumerate), R(1),
B(ForInPrepare), R(2), U8(1),
B(LdaZero),
B(Star), R(5),
/* 65 S> */ B(ForInContinue), R(5), R(4),
B(JumpIfFalse), U8(34),
B(ForInNext), R(1), R(5), R(2), U8(1),
B(JumpIfUndefined), U8(19),
B(Star), R(6),
B(LdaZero),
B(Star), R(8),
B(Ldar), R(6),
/* 65 E> */ B(StaKeyedProperty), R(0), R(8), U8(3),
/* 83 S> */ B(LdaSmi), I8(3),
/* 91 E> */ B(LdaKeyedProperty), R(0), U8(5),
/* 95 S> */ B(Return),
B(ForInStep), R(5),
B(Star), R(5),
/* 59 E> */ B(StackCheck),
B(JumpLoop), U8(34), I8(0),
B(LdaUndefined),
/* 98 S> */ B(Return),
]
constant pool: [
ARRAY_BOILERPLATE_DESCRIPTION_TYPE,
ARRAY_BOILERPLATE_DESCRIPTION_TYPE,
]
handlers: [
]