Commit 26550605 authored by whesse@chromium.org's avatar whesse@chromium.org

Fix errors in x64 crankshaft port, add failing tests to test expectations.

Review URL: http://codereview.chromium.org/6104004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6203 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 7cc06674
// Copyright 2010 the V8 project authors. All rights reserved.
// Copyright 2011 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
......@@ -1497,7 +1497,9 @@ void FullCodeGenerator::VisitAssignment(Assignment* expr) {
if (expr->is_compound()) {
if (property->is_arguments_access()) {
VariableProxy* obj_proxy = property->obj()->AsVariableProxy();
__ push(EmitSlotSearch(obj_proxy->var()->AsSlot(), ecx));
MemOperand slot_operand =
EmitSlotSearch(obj_proxy->var()->AsSlot(), ecx);
__ push(slot_operand);
__ mov(eax, Immediate(property->key()->AsLiteral()->handle()));
} else {
VisitForStackValue(property->obj());
......@@ -1508,7 +1510,9 @@ void FullCodeGenerator::VisitAssignment(Assignment* expr) {
} else {
if (property->is_arguments_access()) {
VariableProxy* obj_proxy = property->obj()->AsVariableProxy();
__ push(EmitSlotSearch(obj_proxy->var()->AsSlot(), ecx));
MemOperand slot_operand =
EmitSlotSearch(obj_proxy->var()->AsSlot(), ecx);
__ push(slot_operand);
__ push(Immediate(property->key()->AsLiteral()->handle()));
} else {
VisitForStackValue(property->obj());
......@@ -3739,7 +3743,9 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) {
} else {
if (prop->is_arguments_access()) {
VariableProxy* obj_proxy = prop->obj()->AsVariableProxy();
__ push(EmitSlotSearch(obj_proxy->var()->AsSlot(), ecx));
MemOperand slot_operand =
EmitSlotSearch(obj_proxy->var()->AsSlot(), ecx);
__ push(slot_operand);
__ mov(eax, Immediate(prop->key()->AsLiteral()->handle()));
} else {
VisitForStackValue(prop->obj());
......
// Copyright 2010 the V8 project authors. All rights reserved.
// Copyright 2011 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
......@@ -459,7 +459,10 @@ void FullCodeGenerator::StackValueContext::Plug(bool flag) const {
void FullCodeGenerator::TestContext::Plug(bool flag) const {
codegen()->PrepareForBailoutBeforeSplit(TOS_REG, true, NULL, NULL);
codegen()->PrepareForBailoutBeforeSplit(TOS_REG,
true,
true_label_,
false_label_);
if (flag) {
if (true_label_ != fall_through_) __ jmp(true_label_);
} else {
......@@ -1380,17 +1383,34 @@ void FullCodeGenerator::VisitAssignment(Assignment* expr) {
VisitForStackValue(property->obj());
}
break;
case KEYED_PROPERTY:
case KEYED_PROPERTY: {
if (expr->is_compound()) {
VisitForStackValue(property->obj());
VisitForAccumulatorValue(property->key());
if (property->is_arguments_access()) {
VariableProxy* obj_proxy = property->obj()->AsVariableProxy();
MemOperand slot_operand =
EmitSlotSearch(obj_proxy->var()->AsSlot(), rcx);
__ push(slot_operand);
__ Move(rax, property->key()->AsLiteral()->handle());
} else {
VisitForStackValue(property->obj());
VisitForAccumulatorValue(property->key());
}
__ movq(rdx, Operand(rsp, 0));
__ push(rax);
} else {
VisitForStackValue(property->obj());
VisitForStackValue(property->key());
if (property->is_arguments_access()) {
VariableProxy* obj_proxy = property->obj()->AsVariableProxy();
MemOperand slot_operand =
EmitSlotSearch(obj_proxy->var()->AsSlot(), rcx);
__ push(slot_operand);
__ Push(property->key()->AsLiteral()->handle());
} else {
VisitForStackValue(property->obj());
VisitForStackValue(property->key());
}
}
break;
}
}
if (expr->is_compound()) {
......@@ -3119,8 +3139,16 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) {
__ push(rax); // Copy of receiver, needed for later store.
EmitNamedPropertyLoad(prop);
} else {
VisitForStackValue(prop->obj());
VisitForAccumulatorValue(prop->key());
if (prop->is_arguments_access()) {
VariableProxy* obj_proxy = prop->obj()->AsVariableProxy();
MemOperand slot_operand =
EmitSlotSearch(obj_proxy->var()->AsSlot(), rcx);
__ push(slot_operand);
__ Move(rax, prop->key()->AsLiteral()->handle());
} else {
VisitForStackValue(prop->obj());
VisitForAccumulatorValue(prop->key());
}
__ movq(rdx, Operand(rsp, 0)); // Leave receiver on stack
__ push(rax); // Copy of key, needed for later store.
EmitKeyedPropertyLoad(prop);
......
# Copyright 2008 the V8 project authors. All rights reserved.
# Copyright 2011 the V8 project authors. All rights reserved.
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
......@@ -56,6 +56,24 @@ test-heap/TestInternalWeakLists: PASS || FAIL
test-heap/TestInternalWeakListsTraverseWithGC: PASS || FAIL
##############################################################################
[ $arch == x64 && $crankshaft ]
# Tests that fail with crankshaft.
test-deoptimization/DeoptimizeBinaryOperationADDString: FAIL
test-deoptimization/DeoptimizeBinaryOperationADD: FAIL
test-deoptimization/DeoptimizeBinaryOperationSUB: FAIL
test-deoptimization/DeoptimizeBinaryOperationMUL: FAIL
test-deoptimization/DeoptimizeBinaryOperationMOD: FAIL
test-deoptimization/DeoptimizeBinaryOperationDIV: FAIL
test-deoptimization/DeoptimizeLoadICStoreIC: FAIL
test-deoptimization/DeoptimizeLoadICStoreICNested: FAIL
test-deoptimization/DeoptimizeCompare: FAIL
# Tests that time out with crankshaft.
test-api/Threading: SKIP
##############################################################################
[ $arch == arm ]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment