Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(210)

Unified Diff: test/cctest/test-api-fast-accessor-builder.cc

Issue 2135153002: Fix FastAccessorAssembler inverted jump conditions (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/fast-accessor-assembler.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-api-fast-accessor-builder.cc
diff --git a/test/cctest/test-api-fast-accessor-builder.cc b/test/cctest/test-api-fast-accessor-builder.cc
index eeb6b96fbccd92fb7d942230995024d2b0367a23..ce22d9a59c160f01a62952e5ea69f8778d9ce8f9 100644
--- a/test/cctest/test-api-fast-accessor-builder.cc
+++ b/test/cctest/test-api-fast-accessor-builder.cc
@@ -189,9 +189,9 @@ TEST(FastAccessorOrReturnNull) {
// CheckFlagSetOrReturnNull:
CompileRun(FN_WARMUP("maskcheck", "return obj.maskcheck"));
obj->SetAlignedPointerInInternalField(1, reinterpret_cast<void*>(0xf0));
- ExpectInt32("maskcheck()", 42);
- obj->SetAlignedPointerInInternalField(1, reinterpret_cast<void*>(0xfe));
ExpectNull("maskcheck()");
+ obj->SetAlignedPointerInInternalField(1, reinterpret_cast<void*>(0xfe));
+ ExpectInt32("maskcheck()", 42);
}
@@ -212,9 +212,9 @@ TEST(FastAccessorControlFlowWithLabels) {
auto label = builder->MakeLabel();
auto val = builder->LoadInternalField(builder->GetReceiver(), 0);
builder->CheckNotZeroOrJump(val, label);
- builder->ReturnValue(builder->IntegerConstant(0));
- builder->SetLabel(label);
builder->ReturnValue(builder->IntegerConstant(1));
+ builder->SetLabel(label);
+ builder->ReturnValue(builder->IntegerConstant(0));
foo->SetAccessorProperty(v8_str("isnull"),
v8::FunctionTemplate::NewWithFastHandler(
isolate, NativePropertyAccessor, builder));
@@ -262,9 +262,9 @@ TEST(FastAccessorLoad) {
auto val = builder->LoadValue(
builder->LoadInternalField(builder->GetReceiver(), 0), intval_offset);
builder->CheckNotZeroOrJump(val, label);
- builder->ReturnValue(builder->IntegerConstant(0));
- builder->SetLabel(label);
builder->ReturnValue(builder->IntegerConstant(1));
+ builder->SetLabel(label);
+ builder->ReturnValue(builder->IntegerConstant(0));
foo->SetAccessorProperty(v8_str("nonzero"),
v8::FunctionTemplate::NewWithFastHandler(
isolate, NativePropertyAccessor, builder));
« no previous file with comments | « src/fast-accessor-assembler.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698