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

Unified Diff: src/a64/full-codegen-a64.cc

Issue 196133017: Experimental parser: merge r19949 (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/parser
Patch Set: Created 6 years, 9 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/a64/frames-a64.cc ('k') | src/a64/ic-a64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/a64/full-codegen-a64.cc
diff --git a/src/a64/full-codegen-a64.cc b/src/a64/full-codegen-a64.cc
index 41ee16e1a92be4aadaed95a3435e2722c9524890..a5f7311717971745a17d9899d51f3f286dda5fa0 100644
--- a/src/a64/full-codegen-a64.cc
+++ b/src/a64/full-codegen-a64.cc
@@ -86,14 +86,14 @@ class JumpPatchSite BASE_EMBEDDED {
}
void EmitJumpIfEitherNotSmi(Register reg1, Register reg2, Label* target) {
- // We need to use ip0, so don't allow access to the MacroAssembler.
- InstructionAccurateScope scope(masm_);
- __ orr(ip0, reg1, reg2);
- EmitJumpIfNotSmi(ip0, target);
+ UseScratchRegisterScope temps(masm_);
+ Register temp = temps.AcquireX();
+ __ Orr(temp, reg1, reg2);
+ EmitJumpIfNotSmi(temp, target);
}
void EmitPatchInfo() {
- Assembler::BlockConstPoolScope scope(masm_);
+ Assembler::BlockPoolsScope scope(masm_);
InlineSmiCheckInfo::Emit(masm_, reg_, &patch_site_);
#ifdef DEBUG
info_emitted_ = true;
@@ -129,8 +129,6 @@ void FullCodeGenerator::Generate() {
handler_table_ =
isolate()->factory()->NewFixedArray(function()->handler_count(), TENURED);
- InitializeFeedbackVector();
-
profiling_counter_ = isolate()->factory()->NewCell(
Handle<Smi>(Smi::FromInt(FLAG_interrupt_budget), isolate()));
SetFunctionPosition(function());
@@ -145,12 +143,12 @@ void FullCodeGenerator::Generate() {
}
#endif
- // Classic mode functions and builtins need to replace the receiver with the
+ // Sloppy mode functions and builtins need to replace the receiver with the
// global proxy when called as functions (without an explicit receiver
// object).
- if (info->is_classic_mode() && !info->is_native()) {
+ if (info->strict_mode() == SLOPPY && !info->is_native()) {
Label ok;
- int receiver_offset = info->scope()->num_parameters() * kXRegSizeInBytes;
+ int receiver_offset = info->scope()->num_parameters() * kXRegSize;
__ Peek(x10, receiver_offset);
__ JumpIfNotRoot(x10, Heap::kUndefinedValueRootIndex, &ok);
@@ -251,12 +249,12 @@ void FullCodeGenerator::Generate() {
// The stub will rewrite receiver and parameter count if the previous
// stack frame was an arguments adapter frame.
ArgumentsAccessStub::Type type;
- if (!is_classic_mode()) {
+ if (strict_mode() == STRICT) {
type = ArgumentsAccessStub::NEW_STRICT;
} else if (function()->has_duplicate_parameters()) {
- type = ArgumentsAccessStub::NEW_NON_STRICT_SLOW;
+ type = ArgumentsAccessStub::NEW_SLOPPY_SLOW;
} else {
- type = ArgumentsAccessStub::NEW_NON_STRICT_FAST;
+ type = ArgumentsAccessStub::NEW_SLOPPY_FAST;
}
ArgumentsAccessStub stub(type);
__ CallStub(&stub);
@@ -281,7 +279,7 @@ void FullCodeGenerator::Generate() {
if (scope()->is_function_scope() && scope()->function() != NULL) {
VariableDeclaration* function = scope()->function();
ASSERT(function->proxy()->var()->mode() == CONST ||
- function->proxy()->var()->mode() == CONST_HARMONY);
+ function->proxy()->var()->mode() == CONST_LEGACY);
ASSERT(function->proxy()->var()->location() != Variable::UNALLOCATED);
VisitVariableDeclaration(function);
}
@@ -350,7 +348,7 @@ void FullCodeGenerator::EmitBackEdgeBookkeeping(IterationStatement* stmt,
ASSERT(jssp.Is(__ StackPointer()));
Comment cmnt(masm_, "[ Back edge bookkeeping");
// Block literal pools whilst emitting back edge code.
- Assembler::BlockConstPoolScope block_const_pool(masm_);
+ Assembler::BlockPoolsScope block_const_pool(masm_);
Label ok;
ASSERT(back_edge_target->is_bound());
@@ -427,7 +425,7 @@ void FullCodeGenerator::EmitReturnSequence() {
ASSERT(!current_sp.Is(csp));
__ mov(current_sp, fp);
int no_frame_start = masm_->pc_offset();
- __ ldp(fp, lr, MemOperand(current_sp, 2 * kXRegSizeInBytes, PostIndex));
+ __ ldp(fp, lr, MemOperand(current_sp, 2 * kXRegSize, PostIndex));
// Drop the arguments and receiver and return.
// TODO(all): This implementation is overkill as it supports 2**31+1
// arguments, consider how to improve it without creating a security
@@ -435,7 +433,7 @@ void FullCodeGenerator::EmitReturnSequence() {
__ LoadLiteral(ip0, 3 * kInstructionSize);
__ add(current_sp, current_sp, ip0);
__ ret();
- __ dc64(kXRegSizeInBytes * (info_->scope()->num_parameters() + 1));
+ __ dc64(kXRegSize * (info_->scope()->num_parameters() + 1));
info_->AddNoFrameRange(no_frame_start, masm_->pc_offset());
}
}
@@ -694,7 +692,7 @@ void FullCodeGenerator::Split(Condition cond,
MemOperand FullCodeGenerator::StackOperand(Variable* var) {
// Offset is negative because higher indexes are at lower addresses.
- int offset = -var->index() * kXRegSizeInBytes;
+ int offset = -var->index() * kXRegSize;
// Adjust by a (parameter or local) base offset.
if (var->IsParameter()) {
offset += (info_->scope()->num_parameters() + 1) * kPointerSize;
@@ -792,7 +790,7 @@ void FullCodeGenerator::VisitVariableDeclaration(
VariableProxy* proxy = declaration->proxy();
VariableMode mode = declaration->mode();
Variable* variable = proxy->var();
- bool hole_init = (mode == CONST) || (mode == CONST_HARMONY) || (mode == LET);
+ bool hole_init = mode == LET || mode == CONST || mode == CONST_LEGACY;
switch (variable->location()) {
case Variable::UNALLOCATED:
@@ -1162,12 +1160,8 @@ void FullCodeGenerator::VisitForInStatement(ForInStatement* stmt) {
// We got a fixed array in register x0. Iterate through that.
__ Bind(&fixed_array);
- Handle<Object> feedback = Handle<Object>(
- Smi::FromInt(TypeFeedbackInfo::kForInFastCaseMarker),
- isolate());
- StoreFeedbackVectorSlot(slot, feedback);
__ LoadObject(x1, FeedbackVector());
- __ Mov(x10, Operand(Smi::FromInt(TypeFeedbackInfo::kForInSlowCaseMarker)));
+ __ Mov(x10, Operand(TypeFeedbackInfo::MegamorphicSentinel(isolate())));
__ Str(x10, FieldMemOperand(x1, FixedArray::OffsetOfElementAt(slot)));
__ Mov(x1, Operand(Smi::FromInt(1))); // Smi indicates slow check.
@@ -1190,18 +1184,18 @@ void FullCodeGenerator::VisitForInStatement(ForInStatement* stmt) {
__ B(hs, loop_statement.break_label());
// Get the current entry of the array into register r3.
- __ Peek(x10, 2 * kXRegSizeInBytes);
+ __ Peek(x10, 2 * kXRegSize);
__ Add(x10, x10, Operand::UntagSmiAndScale(x0, kPointerSizeLog2));
__ Ldr(x3, MemOperand(x10, FixedArray::kHeaderSize - kHeapObjectTag));
// Get the expected map from the stack or a smi in the
// permanent slow case into register x10.
- __ Peek(x2, 3 * kXRegSizeInBytes);
+ __ Peek(x2, 3 * kXRegSize);
// Check if the expected map still matches that of the enumerable.
// If not, we may have to filter the key.
Label update_each;
- __ Peek(x1, 4 * kXRegSizeInBytes);
+ __ Peek(x1, 4 * kXRegSize);
__ Ldr(x11, FieldMemOperand(x1, HeapObject::kMapOffset));
__ Cmp(x11, x2);
__ B(eq, &update_each);
@@ -1326,7 +1320,7 @@ void FullCodeGenerator::EmitNewClosure(Handle<SharedFunctionInfo> info,
!pretenure &&
scope()->is_function_scope() &&
info->num_literals() == 0) {
- FastNewClosureStub stub(info->language_mode(), info->is_generator());
+ FastNewClosureStub stub(info->strict_mode(), info->is_generator());
__ Mov(x2, Operand(info));
__ CallStub(&stub);
} else {
@@ -1356,7 +1350,7 @@ void FullCodeGenerator::EmitLoadGlobalCheckExtensions(Variable* var,
Scope* s = scope();
while (s != NULL) {
if (s->num_heap_slots() > 0) {
- if (s->calls_non_strict_eval()) {
+ if (s->calls_sloppy_eval()) {
// Check that extension is NULL.
__ Ldr(temp, ContextMemOperand(current, Context::EXTENSION_INDEX));
__ Cbnz(temp, slow);
@@ -1368,7 +1362,7 @@ void FullCodeGenerator::EmitLoadGlobalCheckExtensions(Variable* var,
}
// If no outer scope calls eval, we do not need to check more
// context extensions.
- if (!s->outer_scope_calls_non_strict_eval() || s->is_eval_scope()) break;
+ if (!s->outer_scope_calls_sloppy_eval() || s->is_eval_scope()) break;
s = s->outer_scope();
}
@@ -1406,7 +1400,7 @@ MemOperand FullCodeGenerator::ContextSlotOperandCheckExtensions(Variable* var,
for (Scope* s = scope(); s != var->scope(); s = s->outer_scope()) {
if (s->num_heap_slots() > 0) {
- if (s->calls_non_strict_eval()) {
+ if (s->calls_sloppy_eval()) {
// Check that extension is NULL.
__ Ldr(temp, ContextMemOperand(context, Context::EXTENSION_INDEX));
__ Cbnz(temp, slow);
@@ -1442,13 +1436,12 @@ void FullCodeGenerator::EmitDynamicLookupFastCase(Variable* var,
} else if (var->mode() == DYNAMIC_LOCAL) {
Variable* local = var->local_if_not_shadowed();
__ Ldr(x0, ContextSlotOperandCheckExtensions(local, slow));
- if (local->mode() == LET ||
- local->mode() == CONST ||
- local->mode() == CONST_HARMONY) {
+ if (local->mode() == LET || local->mode() == CONST ||
+ local->mode() == CONST_LEGACY) {
__ JumpIfNotRoot(x0, Heap::kTheHoleValueRootIndex, done);
- if (local->mode() == CONST) {
+ if (local->mode() == CONST_LEGACY) {
__ LoadRoot(x0, Heap::kUndefinedValueRootIndex);
- } else { // LET || CONST_HARMONY
+ } else { // LET || CONST
__ Mov(x0, Operand(var->name()));
__ Push(x0);
__ CallRuntime(Runtime::kThrowReferenceError, 1);
@@ -1515,7 +1508,7 @@ void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy) {
// Check that we always have valid source position.
ASSERT(var->initializer_position() != RelocInfo::kNoPosition);
ASSERT(proxy->position() != RelocInfo::kNoPosition);
- skip_init_check = var->mode() != CONST &&
+ skip_init_check = var->mode() != CONST_LEGACY &&
var->initializer_position() < proxy->position();
}
@@ -1524,7 +1517,7 @@ void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy) {
GetVar(x0, var);
Label done;
__ JumpIfNotRoot(x0, Heap::kTheHoleValueRootIndex, &done);
- if (var->mode() == LET || var->mode() == CONST_HARMONY) {
+ if (var->mode() == LET || var->mode() == CONST) {
// Throw a reference error when using an uninitialized let/const
// binding in harmony mode.
__ Mov(x0, Operand(var->name()));
@@ -1533,7 +1526,7 @@ void FullCodeGenerator::EmitVariableLoad(VariableProxy* proxy) {
__ Bind(&done);
} else {
// Uninitalized const bindings outside of harmony mode are unholed.
- ASSERT(var->mode() == CONST);
+ ASSERT(var->mode() == CONST_LEGACY);
__ LoadRoot(x0, Heap::kUndefinedValueRootIndex);
__ Bind(&done);
}
@@ -1640,10 +1633,9 @@ void FullCodeGenerator::VisitObjectLiteral(ObjectLiteral* expr) {
int properties_count = constant_properties->length() / 2;
const int max_cloned_properties =
FastCloneShallowObjectStub::kMaximumClonedProperties;
- if ((FLAG_track_double_fields && expr->may_store_doubles()) ||
- (expr->depth() > 1) || Serializer::enabled() ||
- (flags != ObjectLiteral::kFastElements) ||
- (properties_count > max_cloned_properties)) {
+ if (expr->may_store_doubles() || expr->depth() > 1 || Serializer::enabled() ||
+ flags != ObjectLiteral::kFastElements ||
+ properties_count > max_cloned_properties) {
__ Push(x3, x2, x1, x0);
__ CallRuntime(Runtime::kCreateObjectLiteral, 4);
} else {
@@ -1690,30 +1682,29 @@ void FullCodeGenerator::VisitObjectLiteral(ObjectLiteral* expr) {
}
break;
}
- // Duplicate receiver on stack.
- __ Peek(x0, 0);
- __ Push(x0);
- VisitForStackValue(key);
- VisitForStackValue(value);
if (property->emit_store()) {
+ // Duplicate receiver on stack.
+ __ Peek(x0, 0);
+ __ Push(x0);
+ VisitForStackValue(key);
+ VisitForStackValue(value);
__ Mov(x0, Operand(Smi::FromInt(NONE))); // PropertyAttributes
__ Push(x0);
__ CallRuntime(Runtime::kSetProperty, 4);
} else {
- __ Drop(3);
+ VisitForEffect(key);
+ VisitForEffect(value);
}
break;
case ObjectLiteral::Property::PROTOTYPE:
- // Duplicate receiver on stack.
- __ Peek(x0, 0);
- // TODO(jbramley): This push shouldn't be necessary if we don't call the
- // runtime below. In that case, skip it.
- __ Push(x0);
- VisitForStackValue(value);
if (property->emit_store()) {
+ // Duplicate receiver on stack.
+ __ Peek(x0, 0);
+ __ Push(x0);
+ VisitForStackValue(value);
__ CallRuntime(Runtime::kSetPrototype, 2);
} else {
- __ Drop(2);
+ VisitForEffect(value);
}
break;
case ObjectLiteral::Property::GETTER:
@@ -2007,7 +1998,7 @@ void FullCodeGenerator::EmitInlineSmiBinaryOp(BinaryOperation* expr,
__ Bind(&stub_call);
BinaryOpICStub stub(op, mode);
{
- Assembler::BlockConstPoolScope scope(masm_);
+ Assembler::BlockPoolsScope scope(masm_);
CallIC(stub.GetCode(isolate()), expr->BinaryOperationFeedbackId());
patch_site.EmitPatchInfo();
}
@@ -2062,7 +2053,7 @@ void FullCodeGenerator::EmitInlineSmiBinaryOp(BinaryOperation* expr,
__ B(&done);
__ Bind(&not_minus_zero);
__ Cls(x11, x10);
- __ Cmp(x11, kXRegSize - kSmiShift);
+ __ Cmp(x11, kXRegSizeInBits - kSmiShift);
__ B(lt, &stub_call);
__ SmiTag(result, x10);
__ Bind(&done);
@@ -2093,7 +2084,7 @@ void FullCodeGenerator::EmitBinaryOp(BinaryOperation* expr,
BinaryOpICStub stub(op, mode);
JumpPatchSite patch_site(masm_); // Unbound, signals no inlined smi code.
{
- Assembler::BlockConstPoolScope scope(masm_);
+ Assembler::BlockPoolsScope scope(masm_);
CallIC(stub.GetCode(isolate()), expr->BinaryOperationFeedbackId());
patch_site.EmitPatchInfo();
}
@@ -2144,7 +2135,7 @@ void FullCodeGenerator::EmitAssignment(Expression* expr) {
VisitForAccumulatorValue(prop->key());
__ Mov(x1, x0);
__ Pop(x2, x0);
- Handle<Code> ic = is_classic_mode()
+ Handle<Code> ic = strict_mode() == SLOPPY
? isolate()->builtins()->KeyedStoreIC_Initialize()
: isolate()->builtins()->KeyedStoreIC_Initialize_Strict();
CallIC(ic);
@@ -2169,9 +2160,9 @@ void FullCodeGenerator::EmitStoreToStackLocalOrContextSlot(
void FullCodeGenerator::EmitCallStoreContextSlot(
- Handle<String> name, LanguageMode mode) {
+ Handle<String> name, StrictMode strict_mode) {
__ Mov(x11, Operand(name));
- __ Mov(x10, Operand(Smi::FromInt(mode)));
+ __ Mov(x10, Operand(Smi::FromInt(strict_mode)));
// jssp[0] : mode.
// jssp[8] : name.
// jssp[16] : context.
@@ -2190,7 +2181,7 @@ void FullCodeGenerator::EmitVariableAssignment(Variable* var,
__ Ldr(x1, GlobalObjectMemOperand());
CallStoreIC();
- } else if (op == Token::INIT_CONST) {
+ } else if (op == Token::INIT_CONST_LEGACY) {
// Const initializers need a write barrier.
ASSERT(!var->IsParameter()); // No const parameters.
if (var->IsLookupSlot()) {
@@ -2211,7 +2202,7 @@ void FullCodeGenerator::EmitVariableAssignment(Variable* var,
} else if (var->mode() == LET && op != Token::INIT_LET) {
// Non-initializing assignment to let variable needs a write barrier.
if (var->IsLookupSlot()) {
- EmitCallStoreContextSlot(var->name(), language_mode());
+ EmitCallStoreContextSlot(var->name(), strict_mode());
} else {
ASSERT(var->IsStackAllocated() || var->IsContextSlot());
Label assign;
@@ -2226,11 +2217,11 @@ void FullCodeGenerator::EmitVariableAssignment(Variable* var,
EmitStoreToStackLocalOrContextSlot(var, location);
}
- } else if (!var->is_const_mode() || op == Token::INIT_CONST_HARMONY) {
+ } else if (!var->is_const_mode() || op == Token::INIT_CONST) {
// Assignment to var or initializing assignment to let/const
// in harmony mode.
if (var->IsLookupSlot()) {
- EmitCallStoreContextSlot(var->name(), language_mode());
+ EmitCallStoreContextSlot(var->name(), strict_mode());
} else {
ASSERT(var->IsStackAllocated() || var->IsContextSlot());
MemOperand location = VarOperand(var, x1);
@@ -2274,7 +2265,7 @@ void FullCodeGenerator::EmitKeyedPropertyAssignment(Assignment* expr) {
// TODO(all): Could we pass this in registers rather than on the stack?
__ Pop(x1, x2); // Key and object holding the property.
- Handle<Code> ic = is_classic_mode()
+ Handle<Code> ic = strict_mode() == SLOPPY
? isolate()->builtins()->KeyedStoreIC_Initialize()
: isolate()->builtins()->KeyedStoreIC_Initialize_Strict();
CallIC(ic, expr->AssignmentFeedbackId());
@@ -2328,7 +2319,7 @@ void FullCodeGenerator::EmitCallWithIC(Call* expr) {
PrepareForBailout(callee, NO_REGISTERS);
}
// Push undefined as receiver. This is patched in the method prologue if it
- // is a classic mode method.
+ // is a sloppy mode method.
__ Push(isolate()->factory()->undefined_value());
flags = NO_CALL_FUNCTION_FLAGS;
} else {
@@ -2417,15 +2408,12 @@ void FullCodeGenerator::EmitCallWithStub(Call* expr) {
// Record source position for debugger.
SetSourcePosition(expr->position());
- Handle<Object> uninitialized =
- TypeFeedbackInfo::UninitializedSentinel(isolate());
- StoreFeedbackVectorSlot(expr->CallFeedbackSlot(), uninitialized);
__ LoadObject(x2, FeedbackVector());
__ Mov(x3, Operand(Smi::FromInt(expr->CallFeedbackSlot())));
// Record call targets in unoptimized code.
CallFunctionStub stub(arg_count, RECORD_CALL_TARGET);
- __ Peek(x1, (arg_count + 1) * kXRegSizeInBytes);
+ __ Peek(x1, (arg_count + 1) * kXRegSize);
__ CallStub(&stub);
RecordJSReturnSite(expr);
// Restore context register.
@@ -2439,7 +2427,7 @@ void FullCodeGenerator::EmitResolvePossiblyDirectEval(int arg_count) {
// Prepare to push a copy of the first argument or undefined if it doesn't
// exist.
if (arg_count > 0) {
- __ Peek(x10, arg_count * kXRegSizeInBytes);
+ __ Peek(x10, arg_count * kXRegSize);
} else {
__ LoadRoot(x10, Heap::kUndefinedValueRootIndex);
}
@@ -2452,7 +2440,7 @@ void FullCodeGenerator::EmitResolvePossiblyDirectEval(int arg_count) {
__ Push(x10, x11);
// Prepare to push the language mode.
- __ Mov(x10, Operand(Smi::FromInt(language_mode())));
+ __ Mov(x10, Operand(Smi::FromInt(strict_mode())));
// Prepare to push the start position of the scope the calls resides in.
__ Mov(x11, Operand(Smi::FromInt(scope()->start_position())));
@@ -2510,7 +2498,7 @@ void FullCodeGenerator::VisitCall(Call* expr) {
// Call the evaluated function.
CallFunctionStub stub(arg_count, NO_CALL_FUNCTION_FLAGS);
- __ Peek(x1, (arg_count + 1) * kXRegSizeInBytes);
+ __ Peek(x1, (arg_count + 1) * kXRegSize);
__ CallStub(&stub);
RecordJSReturnSite(expr);
// Restore context register.
@@ -2613,12 +2601,9 @@ void FullCodeGenerator::VisitCallNew(CallNew* expr) {
// Load function and argument count into x1 and x0.
__ Mov(x0, arg_count);
- __ Peek(x1, arg_count * kXRegSizeInBytes);
+ __ Peek(x1, arg_count * kXRegSize);
// Record call targets in unoptimized code.
- Handle<Object> uninitialized =
- TypeFeedbackInfo::UninitializedSentinel(isolate());
- StoreFeedbackVectorSlot(expr->CallNewFeedbackSlot(), uninitialized);
__ LoadObject(x2, FeedbackVector());
__ Mov(x3, Operand(Smi::FromInt(expr->CallNewFeedbackSlot())));
@@ -3892,9 +3877,7 @@ void FullCodeGenerator::VisitUnaryOperation(UnaryOperation* expr) {
if (property != NULL) {
VisitForStackValue(property->obj());
VisitForStackValue(property->key());
- StrictModeFlag strict_mode_flag = (language_mode() == CLASSIC_MODE)
- ? kNonStrictMode : kStrictMode;
- __ Mov(x10, Operand(Smi::FromInt(strict_mode_flag)));
+ __ Mov(x10, Operand(Smi::FromInt(strict_mode())));
__ Push(x10);
__ InvokeBuiltin(Builtins::DELETE, CALL_FUNCTION);
context()->Plug(x0);
@@ -3902,11 +3885,11 @@ void FullCodeGenerator::VisitUnaryOperation(UnaryOperation* expr) {
Variable* var = proxy->var();
// Delete of an unqualified identifier is disallowed in strict mode
// but "delete this" is allowed.
- ASSERT(language_mode() == CLASSIC_MODE || var->is_this());
+ ASSERT(strict_mode() == SLOPPY || var->is_this());
if (var->IsUnallocated()) {
__ Ldr(x12, GlobalObjectMemOperand());
__ Mov(x11, Operand(var->name()));
- __ Mov(x10, Operand(Smi::FromInt(kNonStrictMode)));
+ __ Mov(x10, Operand(Smi::FromInt(SLOPPY)));
__ Push(x12, x11, x10);
__ InvokeBuiltin(Builtins::DELETE, CALL_FUNCTION);
context()->Plug(x0);
@@ -4100,10 +4083,10 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) {
__ Push(x0);
break;
case NAMED_PROPERTY:
- __ Poke(x0, kXRegSizeInBytes);
+ __ Poke(x0, kXRegSize);
break;
case KEYED_PROPERTY:
- __ Poke(x0, 2 * kXRegSizeInBytes);
+ __ Poke(x0, 2 * kXRegSize);
break;
}
}
@@ -4117,7 +4100,7 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) {
SetSourcePosition(expr->position());
{
- Assembler::BlockConstPoolScope scope(masm_);
+ Assembler::BlockPoolsScope scope(masm_);
BinaryOpICStub stub(Token::ADD, NO_OVERWRITE);
CallIC(stub.GetCode(isolate()), expr->CountBinOpFeedbackId());
patch_site.EmitPatchInfo();
@@ -4163,7 +4146,7 @@ void FullCodeGenerator::VisitCountOperation(CountOperation* expr) {
case KEYED_PROPERTY: {
__ Pop(x1); // Key.
__ Pop(x2); // Receiver.
- Handle<Code> ic = is_classic_mode()
+ Handle<Code> ic = strict_mode() == SLOPPY
? isolate()->builtins()->KeyedStoreIC_Initialize()
: isolate()->builtins()->KeyedStoreIC_Initialize_Strict();
CallIC(ic, expr->CountStoreFeedbackId());
« no previous file with comments | « src/a64/frames-a64.cc ('k') | src/a64/ic-a64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698