diff --git a/deps/v8/src/ast-numbering.cc b/deps/v8/src/ast-numbering.cc index dc0528caa0cff6..4becade296fa52 100644 --- a/deps/v8/src/ast-numbering.cc +++ b/deps/v8/src/ast-numbering.cc @@ -553,7 +553,7 @@ bool AstNumberingVisitor::Renumber(FunctionLiteral* node) { Scope* scope = node->scope(); if (scope->HasIllegalRedeclaration()) { - scope->VisitIllegalRedeclaration(this); + Visit(scope->GetIllegalRedeclaration()); DisableOptimization(kFunctionWithIllegalRedeclaration); return Finish(node); } diff --git a/deps/v8/src/compiler/ast-graph-builder.cc b/deps/v8/src/compiler/ast-graph-builder.cc index e7725799233cbb..947d2e3b185f1b 100644 --- a/deps/v8/src/compiler/ast-graph-builder.cc +++ b/deps/v8/src/compiler/ast-graph-builder.cc @@ -586,8 +586,7 @@ void AstGraphBuilder::CreateGraphBody(bool stack_check) { // Visit illegal re-declaration and bail out if it exists. if (scope->HasIllegalRedeclaration()) { - AstEffectContext for_effect(this); - scope->VisitIllegalRedeclaration(this); + VisitForEffect(scope->GetIllegalRedeclaration()); return; } diff --git a/deps/v8/src/compiler/linkage.cc b/deps/v8/src/compiler/linkage.cc index 2bbedaceb26b07..80b5e2616f3262 100644 --- a/deps/v8/src/compiler/linkage.cc +++ b/deps/v8/src/compiler/linkage.cc @@ -218,10 +218,10 @@ int Linkage::FrameStateInputCount(Runtime::FunctionId function) { switch (function) { case Runtime::kAllocateInTargetSpace: case Runtime::kDateField: - case Runtime::kFinalizeClassDefinition: // TODO(conradw): Is it safe? case Runtime::kDefineClassMethod: // TODO(jarin): Is it safe? case Runtime::kDefineGetterPropertyUnchecked: // TODO(jarin): Is it safe? case Runtime::kDefineSetterPropertyUnchecked: // TODO(jarin): Is it safe? + case Runtime::kFinalizeClassDefinition: // TODO(conradw): Is it safe? case Runtime::kForInDone: case Runtime::kForInStep: case Runtime::kGetOriginalConstructor: @@ -244,6 +244,7 @@ int Linkage::FrameStateInputCount(Runtime::FunctionId function) { case Runtime::kInlineGetCallerJSFunction: case Runtime::kInlineGetPrototype: case Runtime::kInlineRegExpExec: + case Runtime::kInlineSubString: case Runtime::kInlineToObject: return 1; case Runtime::kInlineDeoptimizeNow: diff --git a/deps/v8/src/full-codegen/arm/full-codegen-arm.cc b/deps/v8/src/full-codegen/arm/full-codegen-arm.cc index 197a5ecc6fc1f9..56f7e62ded8bae 100644 --- a/deps/v8/src/full-codegen/arm/full-codegen-arm.cc +++ b/deps/v8/src/full-codegen/arm/full-codegen-arm.cc @@ -338,7 +338,7 @@ void FullCodeGenerator::Generate() { // redeclaration. if (scope()->HasIllegalRedeclaration()) { Comment cmnt(masm_, "[ Declarations"); - scope()->VisitIllegalRedeclaration(this); + VisitForEffect(scope()->GetIllegalRedeclaration()); } else { PrepareForBailoutForId(BailoutId::FunctionEntry(), NO_REGISTERS); diff --git a/deps/v8/src/full-codegen/arm64/full-codegen-arm64.cc b/deps/v8/src/full-codegen/arm64/full-codegen-arm64.cc index 73aaf46abde31a..96e8d957d5c543 100644 --- a/deps/v8/src/full-codegen/arm64/full-codegen-arm64.cc +++ b/deps/v8/src/full-codegen/arm64/full-codegen-arm64.cc @@ -344,7 +344,7 @@ void FullCodeGenerator::Generate() { // redeclaration. if (scope()->HasIllegalRedeclaration()) { Comment cmnt(masm_, "[ Declarations"); - scope()->VisitIllegalRedeclaration(this); + VisitForEffect(scope()->GetIllegalRedeclaration()); } else { PrepareForBailoutForId(BailoutId::FunctionEntry(), NO_REGISTERS); diff --git a/deps/v8/src/full-codegen/ia32/full-codegen-ia32.cc b/deps/v8/src/full-codegen/ia32/full-codegen-ia32.cc index 5aa64094413334..1503211b0b8b67 100644 --- a/deps/v8/src/full-codegen/ia32/full-codegen-ia32.cc +++ b/deps/v8/src/full-codegen/ia32/full-codegen-ia32.cc @@ -341,7 +341,7 @@ void FullCodeGenerator::Generate() { // redeclaration. if (scope()->HasIllegalRedeclaration()) { Comment cmnt(masm_, "[ Declarations"); - scope()->VisitIllegalRedeclaration(this); + VisitForEffect(scope()->GetIllegalRedeclaration()); } else { PrepareForBailoutForId(BailoutId::FunctionEntry(), NO_REGISTERS); diff --git a/deps/v8/src/full-codegen/mips/full-codegen-mips.cc b/deps/v8/src/full-codegen/mips/full-codegen-mips.cc index c8da77fba2128c..2f0173191b89ae 100644 --- a/deps/v8/src/full-codegen/mips/full-codegen-mips.cc +++ b/deps/v8/src/full-codegen/mips/full-codegen-mips.cc @@ -356,7 +356,7 @@ void FullCodeGenerator::Generate() { // redeclaration. if (scope()->HasIllegalRedeclaration()) { Comment cmnt(masm_, "[ Declarations"); - scope()->VisitIllegalRedeclaration(this); + VisitForEffect(scope()->GetIllegalRedeclaration()); } else { PrepareForBailoutForId(BailoutId::FunctionEntry(), NO_REGISTERS); diff --git a/deps/v8/src/full-codegen/mips64/full-codegen-mips64.cc b/deps/v8/src/full-codegen/mips64/full-codegen-mips64.cc index 231e8ba3840a77..db25e433dc240c 100644 --- a/deps/v8/src/full-codegen/mips64/full-codegen-mips64.cc +++ b/deps/v8/src/full-codegen/mips64/full-codegen-mips64.cc @@ -351,7 +351,7 @@ void FullCodeGenerator::Generate() { // redeclaration. if (scope()->HasIllegalRedeclaration()) { Comment cmnt(masm_, "[ Declarations"); - scope()->VisitIllegalRedeclaration(this); + VisitForEffect(scope()->GetIllegalRedeclaration()); } else { PrepareForBailoutForId(BailoutId::FunctionEntry(), NO_REGISTERS); diff --git a/deps/v8/src/full-codegen/ppc/full-codegen-ppc.cc b/deps/v8/src/full-codegen/ppc/full-codegen-ppc.cc index 656c37523247f4..5c25c6dc9ed959 100644 --- a/deps/v8/src/full-codegen/ppc/full-codegen-ppc.cc +++ b/deps/v8/src/full-codegen/ppc/full-codegen-ppc.cc @@ -349,7 +349,7 @@ void FullCodeGenerator::Generate() { // redeclaration. if (scope()->HasIllegalRedeclaration()) { Comment cmnt(masm_, "[ Declarations"); - scope()->VisitIllegalRedeclaration(this); + VisitForEffect(scope()->GetIllegalRedeclaration()); } else { PrepareForBailoutForId(BailoutId::FunctionEntry(), NO_REGISTERS); diff --git a/deps/v8/src/full-codegen/x64/full-codegen-x64.cc b/deps/v8/src/full-codegen/x64/full-codegen-x64.cc index 7e0553103f3fff..a9a5e162438a09 100644 --- a/deps/v8/src/full-codegen/x64/full-codegen-x64.cc +++ b/deps/v8/src/full-codegen/x64/full-codegen-x64.cc @@ -338,7 +338,7 @@ void FullCodeGenerator::Generate() { // redeclaration. if (scope()->HasIllegalRedeclaration()) { Comment cmnt(masm_, "[ Declarations"); - scope()->VisitIllegalRedeclaration(this); + VisitForEffect(scope()->GetIllegalRedeclaration()); } else { PrepareForBailoutForId(BailoutId::FunctionEntry(), NO_REGISTERS); diff --git a/deps/v8/src/full-codegen/x87/full-codegen-x87.cc b/deps/v8/src/full-codegen/x87/full-codegen-x87.cc index cfa752c19145db..fdf42cdb8a3c5b 100644 --- a/deps/v8/src/full-codegen/x87/full-codegen-x87.cc +++ b/deps/v8/src/full-codegen/x87/full-codegen-x87.cc @@ -338,7 +338,7 @@ void FullCodeGenerator::Generate() { // redeclaration. if (scope()->HasIllegalRedeclaration()) { Comment cmnt(masm_, "[ Declarations"); - scope()->VisitIllegalRedeclaration(this); + VisitForEffect(scope()->GetIllegalRedeclaration()); } else { PrepareForBailoutForId(BailoutId::FunctionEntry(), NO_REGISTERS); diff --git a/deps/v8/src/isolate.cc b/deps/v8/src/isolate.cc index f63d423fa741c4..1b44ee6834a695 100644 --- a/deps/v8/src/isolate.cc +++ b/deps/v8/src/isolate.cc @@ -1279,9 +1279,14 @@ void Isolate::ComputeLocation(MessageLocation* target) { Object* script = fun->shared()->script(); if (script->IsScript() && !(Script::cast(script)->source()->IsUndefined())) { - int pos = frame->LookupCode()->SourcePosition(frame->pc()); - // Compute the location from the function and the reloc info. Handle