OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_COMPILER_H_ | 5 #ifndef V8_COMPILER_H_ |
6 #define V8_COMPILER_H_ | 6 #define V8_COMPILER_H_ |
7 | 7 |
8 #include "src/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/ast.h" | 9 #include "src/ast.h" |
10 #include "src/bailout-reason.h" | 10 #include "src/bailout-reason.h" |
(...skipping 679 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
690 | 690 |
691 // Compile a String source within a context for eval. | 691 // Compile a String source within a context for eval. |
692 MUST_USE_RESULT static MaybeHandle<JSFunction> GetFunctionFromEval( | 692 MUST_USE_RESULT static MaybeHandle<JSFunction> GetFunctionFromEval( |
693 Handle<String> source, Handle<SharedFunctionInfo> outer_info, | 693 Handle<String> source, Handle<SharedFunctionInfo> outer_info, |
694 Handle<Context> context, StrictMode strict_mode, | 694 Handle<Context> context, StrictMode strict_mode, |
695 ParseRestriction restriction, int scope_position); | 695 ParseRestriction restriction, int scope_position); |
696 | 696 |
697 // Compile a String source within a context. | 697 // Compile a String source within a context. |
698 static Handle<SharedFunctionInfo> CompileScript( | 698 static Handle<SharedFunctionInfo> CompileScript( |
699 Handle<String> source, Handle<Object> script_name, int line_offset, | 699 Handle<String> source, Handle<Object> script_name, int line_offset, |
700 int column_offset, bool is_shared_cross_origin, Handle<Context> context, | 700 int column_offset, bool is_internal_script, bool is_shared_cross_origin, |
701 v8::Extension* extension, ScriptData** cached_data, | 701 Handle<Context> context, v8::Extension* extension, |
702 ScriptCompiler::CompileOptions compile_options, | 702 ScriptData** cached_data, ScriptCompiler::CompileOptions compile_options, |
703 NativesFlag is_natives_code); | 703 NativesFlag is_natives_code); |
704 | 704 |
705 static Handle<SharedFunctionInfo> CompileStreamedScript(CompilationInfo* info, | 705 static Handle<SharedFunctionInfo> CompileStreamedScript(CompilationInfo* info, |
706 int source_length); | 706 int source_length); |
707 | 707 |
708 // Create a shared function info object (the code may be lazily compiled). | 708 // Create a shared function info object (the code may be lazily compiled). |
709 static Handle<SharedFunctionInfo> BuildFunctionInfo(FunctionLiteral* node, | 709 static Handle<SharedFunctionInfo> BuildFunctionInfo(FunctionLiteral* node, |
710 Handle<Script> script, | 710 Handle<Script> script, |
711 CompilationInfo* outer); | 711 CompilationInfo* outer); |
712 | 712 |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
749 Zone zone_; | 749 Zone zone_; |
750 unsigned info_zone_start_allocation_size_; | 750 unsigned info_zone_start_allocation_size_; |
751 base::ElapsedTimer timer_; | 751 base::ElapsedTimer timer_; |
752 | 752 |
753 DISALLOW_COPY_AND_ASSIGN(CompilationPhase); | 753 DISALLOW_COPY_AND_ASSIGN(CompilationPhase); |
754 }; | 754 }; |
755 | 755 |
756 } } // namespace v8::internal | 756 } } // namespace v8::internal |
757 | 757 |
758 #endif // V8_COMPILER_H_ | 758 #endif // V8_COMPILER_H_ |
OLD | NEW |