2016-02-25 12:07:07 +00:00
|
|
|
#
|
|
|
|
# Autogenerated by generate-bytecode-expectations.
|
|
|
|
#
|
|
|
|
|
|
|
|
---
|
|
|
|
wrap: yes
|
|
|
|
|
|
|
|
---
|
|
|
|
snippet: "
|
|
|
|
var x = 0;
|
|
|
|
while (x != 10) {
|
|
|
|
x = x + 10;
|
|
|
|
}
|
|
|
|
return x;
|
|
|
|
"
|
2016-05-27 15:57:35 +00:00
|
|
|
frame size: 1
|
2016-02-25 12:07:07 +00:00
|
|
|
parameter count: 1
|
2016-12-08 10:11:06 +00:00
|
|
|
bytecode array length: 25
|
2016-02-25 12:07:07 +00:00
|
|
|
bytecodes: [
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 30 E> */ B(StackCheck),
|
|
|
|
/* 42 S> */ B(LdaZero),
|
2016-06-09 13:32:33 +00:00
|
|
|
B(Star), R(0),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 54 S> */ B(LdaSmi), I8(10),
|
2016-09-14 10:20:08 +00:00
|
|
|
/* 54 E> */ B(TestEqual), R(0), U8(2),
|
2016-12-08 10:11:06 +00:00
|
|
|
B(JumpIfTrue), U8(13),
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 45 E> */ B(StackCheck),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 65 S> */ B(LdaSmi), I8(10),
|
2016-12-08 10:11:06 +00:00
|
|
|
/* 71 E> */ B(Add), R(0), U8(3),
|
2016-06-09 13:32:33 +00:00
|
|
|
B(Star), R(0),
|
2017-01-25 17:39:24 +00:00
|
|
|
B(JumpLoop), U8(15), I8(0),
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 79 S> */ B(Ldar), R(0),
|
|
|
|
/* 89 S> */ B(Return),
|
2016-02-25 12:07:07 +00:00
|
|
|
]
|
|
|
|
constant pool: [
|
|
|
|
]
|
|
|
|
handlers: [
|
|
|
|
]
|
|
|
|
|
|
|
|
---
|
|
|
|
snippet: "
|
|
|
|
var x = false;
|
|
|
|
do {
|
|
|
|
x = !x;
|
|
|
|
} while(x == false);
|
|
|
|
return x;
|
|
|
|
"
|
2016-05-27 15:57:35 +00:00
|
|
|
frame size: 1
|
2016-02-25 12:07:07 +00:00
|
|
|
parameter count: 1
|
2016-09-13 13:07:15 +00:00
|
|
|
bytecode array length: 22
|
2016-02-25 12:07:07 +00:00
|
|
|
bytecodes: [
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 30 E> */ B(StackCheck),
|
|
|
|
/* 42 S> */ B(LdaFalse),
|
2016-06-09 13:32:33 +00:00
|
|
|
B(Star), R(0),
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 49 E> */ B(StackCheck),
|
|
|
|
/* 56 S> */ B(Ldar), R(0),
|
2016-05-17 20:39:45 +00:00
|
|
|
B(ToBooleanLogicalNot),
|
2016-06-09 13:32:33 +00:00
|
|
|
B(Star), R(0),
|
2016-05-27 15:57:35 +00:00
|
|
|
/* 74 S> */ B(LdaFalse),
|
2016-09-14 10:20:08 +00:00
|
|
|
/* 74 E> */ B(TestEqual), R(0), U8(2),
|
2016-09-13 13:07:15 +00:00
|
|
|
B(JumpIfFalse), U8(5),
|
2017-01-25 17:39:24 +00:00
|
|
|
B(JumpLoop), U8(12), I8(0),
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 85 S> */ B(Ldar), R(0),
|
|
|
|
/* 95 S> */ B(Return),
|
2016-02-25 12:07:07 +00:00
|
|
|
]
|
|
|
|
constant pool: [
|
|
|
|
]
|
|
|
|
handlers: [
|
|
|
|
]
|
|
|
|
|
|
|
|
---
|
|
|
|
snippet: "
|
|
|
|
var x = 101;
|
|
|
|
return void(x * 3);
|
|
|
|
"
|
2016-05-27 15:57:35 +00:00
|
|
|
frame size: 1
|
2016-02-25 12:07:07 +00:00
|
|
|
parameter count: 1
|
2016-08-08 01:15:22 +00:00
|
|
|
bytecode array length: 12
|
2016-02-25 12:07:07 +00:00
|
|
|
bytecodes: [
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 30 E> */ B(StackCheck),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 42 S> */ B(LdaSmi), I8(101),
|
2016-05-23 13:31:53 +00:00
|
|
|
B(Star), R(0),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 47 S> */ B(LdaSmi), I8(3),
|
2016-12-08 10:11:06 +00:00
|
|
|
/* 61 E> */ B(Mul), R(0), U8(2),
|
2016-05-11 12:21:56 +00:00
|
|
|
B(LdaUndefined),
|
|
|
|
/* 67 S> */ B(Return),
|
2016-02-25 12:07:07 +00:00
|
|
|
]
|
|
|
|
constant pool: [
|
|
|
|
]
|
|
|
|
handlers: [
|
|
|
|
]
|
|
|
|
|
|
|
|
---
|
|
|
|
snippet: "
|
|
|
|
var x = 1234;
|
|
|
|
var y = void (x * x - 1);
|
|
|
|
return y;
|
|
|
|
"
|
2016-09-30 09:02:59 +00:00
|
|
|
frame size: 3
|
2016-02-25 12:07:07 +00:00
|
|
|
parameter count: 1
|
2016-11-10 10:41:48 +00:00
|
|
|
bytecode array length: 22
|
2016-02-25 12:07:07 +00:00
|
|
|
bytecodes: [
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 30 E> */ B(StackCheck),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 42 S> */ B(Wide), B(LdaSmi), I16(1234),
|
2016-05-23 13:31:53 +00:00
|
|
|
B(Star), R(0),
|
2016-05-27 15:57:35 +00:00
|
|
|
/* 56 S> */ B(Nop),
|
2016-12-08 10:11:06 +00:00
|
|
|
/* 64 E> */ B(Mul), R(0), U8(2),
|
2016-09-30 09:02:59 +00:00
|
|
|
B(Star), R(2),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 68 E> */ B(SubSmi), I8(1), R(2), U8(3),
|
2016-11-10 10:41:48 +00:00
|
|
|
B(LdaUndefined),
|
|
|
|
B(Star), R(1),
|
2016-05-23 13:31:53 +00:00
|
|
|
/* 74 S> */ B(Nop),
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 84 S> */ B(Return),
|
2016-02-25 12:07:07 +00:00
|
|
|
]
|
|
|
|
constant pool: [
|
|
|
|
]
|
|
|
|
handlers: [
|
|
|
|
]
|
|
|
|
|
|
|
|
---
|
|
|
|
snippet: "
|
|
|
|
var x = 13;
|
|
|
|
return ~x;
|
|
|
|
"
|
2016-05-27 15:57:35 +00:00
|
|
|
frame size: 1
|
2016-02-25 12:07:07 +00:00
|
|
|
parameter count: 1
|
2016-08-08 01:15:22 +00:00
|
|
|
bytecode array length: 11
|
2016-02-25 12:07:07 +00:00
|
|
|
bytecodes: [
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 30 E> */ B(StackCheck),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 42 S> */ B(LdaSmi), I8(13),
|
2016-05-23 13:31:53 +00:00
|
|
|
B(Star), R(0),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 46 S> */ B(LdaSmi), I8(-1),
|
2016-12-08 10:11:06 +00:00
|
|
|
/* 53 E> */ B(BitwiseXor), R(0), U8(2),
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 57 S> */ B(Return),
|
2016-02-25 12:07:07 +00:00
|
|
|
]
|
|
|
|
constant pool: [
|
|
|
|
]
|
|
|
|
handlers: [
|
|
|
|
]
|
|
|
|
|
|
|
|
---
|
|
|
|
snippet: "
|
|
|
|
var x = 13;
|
|
|
|
return +x;
|
|
|
|
"
|
2016-05-27 15:57:35 +00:00
|
|
|
frame size: 1
|
2016-02-25 12:07:07 +00:00
|
|
|
parameter count: 1
|
2016-08-08 01:15:22 +00:00
|
|
|
bytecode array length: 11
|
2016-02-25 12:07:07 +00:00
|
|
|
bytecodes: [
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 30 E> */ B(StackCheck),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 42 S> */ B(LdaSmi), I8(13),
|
2016-05-23 13:31:53 +00:00
|
|
|
B(Star), R(0),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 46 S> */ B(LdaSmi), I8(1),
|
2016-12-08 10:11:06 +00:00
|
|
|
/* 53 E> */ B(Mul), R(0), U8(2),
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 57 S> */ B(Return),
|
2016-02-25 12:07:07 +00:00
|
|
|
]
|
|
|
|
constant pool: [
|
|
|
|
]
|
|
|
|
handlers: [
|
|
|
|
]
|
|
|
|
|
|
|
|
---
|
|
|
|
snippet: "
|
|
|
|
var x = 13;
|
|
|
|
return -x;
|
|
|
|
"
|
2016-05-27 15:57:35 +00:00
|
|
|
frame size: 1
|
2016-02-25 12:07:07 +00:00
|
|
|
parameter count: 1
|
2016-08-08 01:15:22 +00:00
|
|
|
bytecode array length: 11
|
2016-02-25 12:07:07 +00:00
|
|
|
bytecodes: [
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 30 E> */ B(StackCheck),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 42 S> */ B(LdaSmi), I8(13),
|
2016-05-23 13:31:53 +00:00
|
|
|
B(Star), R(0),
|
2017-01-25 17:39:24 +00:00
|
|
|
/* 46 S> */ B(LdaSmi), I8(-1),
|
2016-12-08 10:11:06 +00:00
|
|
|
/* 53 E> */ B(Mul), R(0), U8(2),
|
2016-05-11 12:21:56 +00:00
|
|
|
/* 57 S> */ B(Return),
|
2016-02-25 12:07:07 +00:00
|
|
|
]
|
|
|
|
constant pool: [
|
|
|
|
]
|
|
|
|
handlers: [
|
|
|
|
]
|
|
|
|
|