[Interpreter]: Fix ObjectLiterals test for arm64-sim-nosnap bot.

The AccessorsTable has a non-deterministic iteration order depending on the
random seed. This means that the order of the accessor defines could vary
and the test which tried to set accessors on two different properties
could flakly fail due to the order not being as expected. To fix this I make
the test only do a setter on one property (the test-interpreter.cc test
does the check on multiple property accessors

BUG=v8:4280
LOG=N

Review URL: https://codereview.chromium.org/1404793002

Cr-Commit-Position: refs/heads/master@{#31264}
This commit is contained in:
rmcilroy 2015-10-14 07:51:55 -07:00 committed by Commit bot
parent a456134b8b
commit 1919fa38c2

View File

@ -2234,31 +2234,20 @@ TEST(ObjectLiterals) {
InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE,
InstanceType::SHARED_FUNCTION_INFO_TYPE,
InstanceType::SHARED_FUNCTION_INFO_TYPE}},
{"return { get a() { return this.x; }, set b(val) { this.y = val } };",
{"return { set b(val) { this.y = val } };",
5 * kPointerSize,
1,
52,
31,
{
B(LdaConstant), U8(0), //
B(CreateObjectLiteral), U8(0), U8(deep_elements_flags), //
B(Star), R(0), //
B(LdaConstant), U8(1), //
B(Star), R(1), //
B(LdaNull), //
B(Star), R(2), //
B(LdaConstant), U8(2), //
B(CreateClosure), U8(0), //
B(Star), R(2), //
B(LdaNull), //
B(Star), R(3), //
B(LdaZero), //
B(Star), R(4), //
B(CallRuntime), U16(Runtime::kDefineAccessorPropertyUnchecked), //
R(0), U8(5), //
B(LdaConstant), U8(3), //
B(Star), R(1), //
B(LdaNull), //
B(Star), R(2), //
B(LdaConstant), U8(4), //
B(CreateClosure), U8(0), //
B(Star), R(3), //
B(LdaZero), //
B(Star), R(4), //
@ -2267,10 +2256,8 @@ TEST(ObjectLiterals) {
B(Ldar), R(0), //
B(Return), //
},
5,
3,
{InstanceType::FIXED_ARRAY_TYPE,
InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE,
InstanceType::SHARED_FUNCTION_INFO_TYPE,
InstanceType::ONE_BYTE_INTERNALIZED_STRING_TYPE,
InstanceType::SHARED_FUNCTION_INFO_TYPE}},
{"var a = 1; return { 1: a };",