Index: src/full-codegen/ia32/full-codegen-ia32.cc |
diff --git a/src/full-codegen/ia32/full-codegen-ia32.cc b/src/full-codegen/ia32/full-codegen-ia32.cc |
index 946ed8f83c3c847fa0284c7c90dd00428cbf4b00..a851044bd6fd2491ea82633f7833f4ba430fc852 100644 |
--- a/src/full-codegen/ia32/full-codegen-ia32.cc |
+++ b/src/full-codegen/ia32/full-codegen-ia32.cc |
@@ -1167,7 +1167,7 @@ void FullCodeGenerator::EmitSetHomeObject(Expression* initializer, int offset, |
__ mov(StoreDescriptor::NameRegister(), |
Immediate(isolate()->factory()->home_object_symbol())); |
__ mov(StoreDescriptor::ValueRegister(), Operand(esp, offset * kPointerSize)); |
- if (FLAG_vector_stores) EmitLoadStoreICSlot(slot); |
+ EmitLoadStoreICSlot(slot); |
CallStoreIC(); |
} |
@@ -1180,7 +1180,7 @@ void FullCodeGenerator::EmitSetHomeObjectAccumulator(Expression* initializer, |
__ mov(StoreDescriptor::NameRegister(), |
Immediate(isolate()->factory()->home_object_symbol())); |
__ mov(StoreDescriptor::ValueRegister(), Operand(esp, offset * kPointerSize)); |
- if (FLAG_vector_stores) EmitLoadStoreICSlot(slot); |
+ EmitLoadStoreICSlot(slot); |
CallStoreIC(); |
} |
@@ -1509,12 +1509,8 @@ void FullCodeGenerator::VisitObjectLiteral(ObjectLiteral* expr) { |
DCHECK(StoreDescriptor::ValueRegister().is(eax)); |
__ mov(StoreDescriptor::NameRegister(), Immediate(key->value())); |
__ mov(StoreDescriptor::ReceiverRegister(), Operand(esp, 0)); |
- if (FLAG_vector_stores) { |
- EmitLoadStoreICSlot(property->GetSlot(0)); |
- CallStoreIC(); |
- } else { |
- CallStoreIC(key->LiteralFeedbackId()); |
- } |
+ EmitLoadStoreICSlot(property->GetSlot(0)); |
+ CallStoreIC(); |
PrepareForBailoutForId(key->id(), NO_REGISTERS); |
if (NeedsHomeObject(value)) { |
EmitSetHomeObjectAccumulator(value, 0, property->GetSlot(1)); |
@@ -1699,31 +1695,13 @@ void FullCodeGenerator::VisitArrayLiteral(ArrayLiteral* expr) { |
} |
VisitForAccumulatorValue(subexpr); |
- if (FLAG_vector_stores) { |
- __ mov(StoreDescriptor::NameRegister(), |
- Immediate(Smi::FromInt(array_index))); |
- __ mov(StoreDescriptor::ReceiverRegister(), Operand(esp, kPointerSize)); |
- EmitLoadStoreICSlot(expr->LiteralFeedbackSlot()); |
- Handle<Code> ic = |
- CodeFactory::KeyedStoreIC(isolate(), language_mode()).code(); |
- CallIC(ic); |
- } else if (has_constant_fast_elements) { |
- // Fast-case array literal with ElementsKind of FAST_*_ELEMENTS, they |
- // cannot transition and don't need to call the runtime stub. |
- int offset = FixedArray::kHeaderSize + (array_index * kPointerSize); |
- __ mov(ebx, Operand(esp, kPointerSize)); // Copy of array literal. |
- __ mov(ebx, FieldOperand(ebx, JSObject::kElementsOffset)); |
- // Store the subexpression value in the array's elements. |
- __ mov(FieldOperand(ebx, offset), result_register()); |
- // Update the write barrier for the array store. |
- __ RecordWriteField(ebx, offset, result_register(), ecx, kDontSaveFPRegs, |
- EMIT_REMEMBERED_SET, INLINE_SMI_CHECK); |
- } else { |
- // Store the subexpression value in the array's elements. |
- __ mov(ecx, Immediate(Smi::FromInt(array_index))); |
- StoreArrayLiteralElementStub stub(isolate()); |
- __ CallStub(&stub); |
- } |
+ __ mov(StoreDescriptor::NameRegister(), |
+ Immediate(Smi::FromInt(array_index))); |
+ __ mov(StoreDescriptor::ReceiverRegister(), Operand(esp, kPointerSize)); |
+ EmitLoadStoreICSlot(expr->LiteralFeedbackSlot()); |
+ Handle<Code> ic = |
+ CodeFactory::KeyedStoreIC(isolate(), language_mode()).code(); |
+ CallIC(ic); |
PrepareForBailoutForId(expr->GetIdForElement(array_index), NO_REGISTERS); |
} |
@@ -2414,7 +2392,7 @@ void FullCodeGenerator::EmitAssignment(Expression* expr, |
__ pop(StoreDescriptor::ValueRegister()); // Restore value. |
__ mov(StoreDescriptor::NameRegister(), |
prop->key()->AsLiteral()->value()); |
- if (FLAG_vector_stores) EmitLoadStoreICSlot(slot); |
+ EmitLoadStoreICSlot(slot); |
CallStoreIC(); |
break; |
} |
@@ -2462,7 +2440,7 @@ void FullCodeGenerator::EmitAssignment(Expression* expr, |
__ Move(StoreDescriptor::NameRegister(), eax); |
__ pop(StoreDescriptor::ReceiverRegister()); // Receiver. |
__ pop(StoreDescriptor::ValueRegister()); // Restore value. |
- if (FLAG_vector_stores) EmitLoadStoreICSlot(slot); |
+ EmitLoadStoreICSlot(slot); |
Handle<Code> ic = |
CodeFactory::KeyedStoreIC(isolate(), language_mode()).code(); |
CallIC(ic); |
@@ -2490,7 +2468,7 @@ void FullCodeGenerator::EmitVariableAssignment(Variable* var, Token::Value op, |
// Global var, const, or let. |
__ mov(StoreDescriptor::NameRegister(), var->name()); |
__ mov(StoreDescriptor::ReceiverRegister(), GlobalObjectOperand()); |
- if (FLAG_vector_stores) EmitLoadStoreICSlot(slot); |
+ EmitLoadStoreICSlot(slot); |
CallStoreIC(); |
} else if (var->mode() == LET && op != Token::INIT) { |
@@ -2596,12 +2574,8 @@ void FullCodeGenerator::EmitNamedPropertyAssignment(Assignment* expr) { |
__ mov(StoreDescriptor::NameRegister(), prop->key()->AsLiteral()->value()); |
__ pop(StoreDescriptor::ReceiverRegister()); |
- if (FLAG_vector_stores) { |
- EmitLoadStoreICSlot(expr->AssignmentSlot()); |
- CallStoreIC(); |
- } else { |
- CallStoreIC(expr->AssignmentFeedbackId()); |
- } |
+ EmitLoadStoreICSlot(expr->AssignmentSlot()); |
+ CallStoreIC(); |
PrepareForBailoutForId(expr->AssignmentId(), TOS_REG); |
context()->Plug(eax); |
} |
@@ -2647,13 +2621,8 @@ void FullCodeGenerator::EmitKeyedPropertyAssignment(Assignment* expr) { |
DCHECK(StoreDescriptor::ValueRegister().is(eax)); |
Handle<Code> ic = |
CodeFactory::KeyedStoreIC(isolate(), language_mode()).code(); |
- if (FLAG_vector_stores) { |
- EmitLoadStoreICSlot(expr->AssignmentSlot()); |
- CallIC(ic); |
- } else { |
- CallIC(ic, expr->AssignmentFeedbackId()); |
- } |
- |
+ EmitLoadStoreICSlot(expr->AssignmentSlot()); |
+ CallIC(ic); |
PrepareForBailoutForId(expr->AssignmentId(), TOS_REG); |
context()->Plug(eax); |
} |
@@ -4528,12 +4497,8 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) { |
__ mov(StoreDescriptor::NameRegister(), |
prop->key()->AsLiteral()->value()); |
__ pop(StoreDescriptor::ReceiverRegister()); |
- if (FLAG_vector_stores) { |
- EmitLoadStoreICSlot(expr->CountSlot()); |
- CallStoreIC(); |
- } else { |
- CallStoreIC(expr->CountStoreFeedbackId()); |
- } |
+ EmitLoadStoreICSlot(expr->CountSlot()); |
+ CallStoreIC(); |
PrepareForBailoutForId(expr->AssignmentId(), TOS_REG); |
if (expr->is_postfix()) { |
if (!context()->IsEffect()) { |
@@ -4571,12 +4536,8 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) { |
__ pop(StoreDescriptor::ReceiverRegister()); |
Handle<Code> ic = |
CodeFactory::KeyedStoreIC(isolate(), language_mode()).code(); |
- if (FLAG_vector_stores) { |
- EmitLoadStoreICSlot(expr->CountSlot()); |
- CallIC(ic); |
- } else { |
- CallIC(ic, expr->CountStoreFeedbackId()); |
- } |
+ EmitLoadStoreICSlot(expr->CountSlot()); |
+ CallIC(ic); |
PrepareForBailoutForId(expr->AssignmentId(), TOS_REG); |
if (expr->is_postfix()) { |
// Result is on the stack |
@@ -4876,7 +4837,7 @@ void FullCodeGenerator::ClearPendingMessage() { |
void FullCodeGenerator::EmitLoadStoreICSlot(FeedbackVectorSlot slot) { |
- DCHECK(FLAG_vector_stores && !slot.IsInvalid()); |
+ DCHECK(!slot.IsInvalid()); |
__ mov(VectorStoreICTrampolineDescriptor::SlotRegister(), |
Immediate(SmiFromSlot(slot))); |
} |