diff --git a/deps/v8/include/v8-version.h b/deps/v8/include/v8-version.h index 5f59b89dc865a0..f10bf50780a9cb 100644 --- a/deps/v8/include/v8-version.h +++ b/deps/v8/include/v8-version.h @@ -11,7 +11,7 @@ #define V8_MAJOR_VERSION 4 #define V8_MINOR_VERSION 2 #define V8_BUILD_NUMBER 77 -#define V8_PATCH_LEVEL 18 +#define V8_PATCH_LEVEL 20 // Use 1 for candidates and 0 otherwise. // (Boolean macro values are not supported by all preprocessors.) diff --git a/deps/v8/src/compiler.cc b/deps/v8/src/compiler.cc index d794ae2b204ec3..2bad9e69ea6768 100644 --- a/deps/v8/src/compiler.cc +++ b/deps/v8/src/compiler.cc @@ -1455,7 +1455,7 @@ Handle Compiler::BuildFunctionInfo( result->set_is_toplevel(false); RecordFunctionCompilation(Logger::FUNCTION_TAG, &info, result); - result->set_allows_lazy_compilation(allow_lazy); + result->set_allows_lazy_compilation(literal->AllowsLazyCompilation()); result->set_allows_lazy_compilation_without_context(allow_lazy_without_ctx); // Set the expected number of properties for instances and return diff --git a/deps/v8/src/compiler/graph-visualizer.h b/deps/v8/src/compiler/graph-visualizer.h index 17094c23c57c37..0e6a6471b84a63 100644 --- a/deps/v8/src/compiler/graph-visualizer.h +++ b/deps/v8/src/compiler/graph-visualizer.h @@ -5,6 +5,7 @@ #ifndef V8_COMPILER_GRAPH_VISUALIZER_H_ #define V8_COMPILER_GRAPH_VISUALIZER_H_ +#include #include namespace v8 { diff --git a/deps/v8/src/debug.cc b/deps/v8/src/debug.cc index 324d96f333fa21..a7bf7655814ec5 100644 --- a/deps/v8/src/debug.cc +++ b/deps/v8/src/debug.cc @@ -1604,23 +1604,22 @@ Handle Debug::GetSourceBreakLocations( Handle locations = isolate->factory()->NewFixedArray(debug_info->GetBreakPointCount()); int count = 0; - for (int i = 0; i < debug_info->break_points()->length(); i++) { + for (int i = 0; i < debug_info->break_points()->length(); ++i) { if (!debug_info->break_points()->get(i)->IsUndefined()) { BreakPointInfo* break_point_info = BreakPointInfo::cast(debug_info->break_points()->get(i)); - if (break_point_info->GetBreakPointCount() > 0) { - Smi* position = NULL; - switch (position_alignment) { - case STATEMENT_ALIGNED: - position = break_point_info->statement_position(); - break; - case BREAK_POSITION_ALIGNED: - position = break_point_info->source_position(); - break; - } - - locations->set(count++, position); + int break_points = break_point_info->GetBreakPointCount(); + if (break_points == 0) continue; + Smi* position = NULL; + switch (position_alignment) { + case STATEMENT_ALIGNED: + position = break_point_info->statement_position(); + break; + case BREAK_POSITION_ALIGNED: + position = break_point_info->source_position(); + break; } + for (int j = 0; j < break_points; ++j) locations->set(count++, position); } } return locations; @@ -1923,7 +1922,6 @@ static void RecompileAndRelocateSuspendedGenerators( static bool SkipSharedFunctionInfo(SharedFunctionInfo* shared, Object* active_code_marker) { if (!shared->allows_lazy_compilation()) return true; - if (!shared->script()->IsScript()) return true; Object* script = shared->script(); if (!script->IsScript()) return true; if (Script::cast(script)->type()->value() == Script::TYPE_NATIVE) return true; @@ -2204,6 +2202,21 @@ Object* Debug::FindSharedFunctionInfoInScript(Handle