| Index: src/compiler.cc
|
| diff --git a/src/compiler.cc b/src/compiler.cc
|
| index 9fe7904722aefa5496270f7a451acf9976ff2739..bf36da3180a314647cea89322d7c66a26177d1e6 100644
|
| --- a/src/compiler.cc
|
| +++ b/src/compiler.cc
|
| @@ -533,8 +533,7 @@ bool CompileUnoptimizedInnerFunctionsRecursively(
|
| continue;
|
| } else {
|
| // Otherwise generate unoptimized code now.
|
| - Zone zone(isolate->allocator(), ZONE_NAME);
|
| - ParseInfo parse_info(&zone, script);
|
| + ParseInfo parse_info(script);
|
| CompilationInfo info(&parse_info, Handle<JSFunction>::null());
|
|
|
| parse_info.set_literal(literal);
|
| @@ -919,8 +918,7 @@ MaybeHandle<Code> GetBaselineCode(Handle<JSFunction> function) {
|
| Isolate* isolate = function->GetIsolate();
|
| VMState<COMPILER> state(isolate);
|
| PostponeInterruptsScope postpone(isolate);
|
| - Zone zone(isolate->allocator(), ZONE_NAME);
|
| - ParseInfo parse_info(&zone, handle(function->shared()));
|
| + ParseInfo parse_info(handle(function->shared()));
|
| CompilationInfo info(&parse_info, function);
|
|
|
| DCHECK(function->shared()->is_compiled());
|
| @@ -1053,8 +1051,7 @@ MaybeHandle<Code> GetLazyCode(Handle<JSFunction> function) {
|
| return entry;
|
| }
|
|
|
| - Zone zone(isolate->allocator(), ZONE_NAME);
|
| - ParseInfo parse_info(&zone, handle(function->shared()));
|
| + ParseInfo parse_info(handle(function->shared()));
|
| CompilationInfo info(&parse_info, function);
|
| Handle<Code> result;
|
| ASSIGN_RETURN_ON_EXCEPTION(isolate, result, GetUnoptimizedCode(&info), Code);
|
| @@ -1236,8 +1233,7 @@ bool Compiler::CompileOptimized(Handle<JSFunction> function,
|
| code = isolate->builtins()->InterpreterEntryTrampoline();
|
| function->shared()->ReplaceCode(*code);
|
| } else {
|
| - Zone zone(isolate->allocator(), ZONE_NAME);
|
| - ParseInfo parse_info(&zone, handle(function->shared()));
|
| + ParseInfo parse_info(handle(function->shared()));
|
| CompilationInfo info(&parse_info, function);
|
| if (!GetUnoptimizedCode(&info).ToHandle(&code)) {
|
| return false;
|
| @@ -1261,8 +1257,7 @@ bool Compiler::CompileDebugCode(Handle<SharedFunctionInfo> shared) {
|
| DCHECK(AllowCompilation::IsAllowed(isolate));
|
|
|
| // Start a compilation.
|
| - Zone zone(isolate->allocator(), ZONE_NAME);
|
| - ParseInfo parse_info(&zone, shared);
|
| + ParseInfo parse_info(shared);
|
| CompilationInfo info(&parse_info, Handle<JSFunction>::null());
|
| info.MarkAsDebug();
|
| if (GetUnoptimizedCode(&info).is_null()) {
|
| @@ -1289,8 +1284,7 @@ MaybeHandle<JSArray> Compiler::CompileForLiveEdit(Handle<Script> script) {
|
| script->set_shared_function_infos(isolate->heap()->empty_fixed_array());
|
|
|
| // Start a compilation.
|
| - Zone zone(isolate->allocator(), ZONE_NAME);
|
| - ParseInfo parse_info(&zone, script);
|
| + ParseInfo parse_info(script);
|
| CompilationInfo info(&parse_info, Handle<JSFunction>::null());
|
| info.MarkAsDebug();
|
|
|
| @@ -1301,7 +1295,7 @@ MaybeHandle<JSArray> Compiler::CompileForLiveEdit(Handle<Script> script) {
|
| // Check postconditions on success.
|
| DCHECK(!isolate->has_pending_exception());
|
| infos = LiveEditFunctionTracker::Collect(parse_info.literal(), script,
|
| - &zone, isolate);
|
| + parse_info.zone(), isolate);
|
| }
|
|
|
| // Restore the original function info list in order to remain side-effect
|
| @@ -1425,8 +1419,7 @@ MaybeHandle<JSFunction> Compiler::GetFunctionFromEval(
|
| script->set_compilation_type(Script::COMPILATION_TYPE_EVAL);
|
| Script::SetEvalOrigin(script, outer_info, eval_position);
|
|
|
| - Zone zone(isolate->allocator(), ZONE_NAME);
|
| - ParseInfo parse_info(&zone, script);
|
| + ParseInfo parse_info(script);
|
| CompilationInfo info(&parse_info, Handle<JSFunction>::null());
|
| parse_info.set_eval();
|
| parse_info.set_language_mode(language_mode);
|
| @@ -1605,8 +1598,7 @@ Handle<SharedFunctionInfo> Compiler::GetSharedFunctionInfoForScript(
|
| }
|
|
|
| // Compile the function and add it to the cache.
|
| - Zone zone(isolate->allocator(), ZONE_NAME);
|
| - ParseInfo parse_info(&zone, script);
|
| + ParseInfo parse_info(script);
|
| CompilationInfo info(&parse_info, Handle<JSFunction>::null());
|
| if (is_module) parse_info.set_module();
|
| if (compile_options != ScriptCompiler::kNoCompileOptions) {
|
|
|