Lines Matching refs:shared

256 int CompilationInfo::TraceInlinedFunction(Handle<SharedFunctionInfo> shared,  in TraceInlinedFunction()  argument
263 shared->start_position()); in TraceInlinedFunction()
264 if (!shared->script()->IsUndefined()) { in TraceInlinedFunction()
265 Handle<Script> script(Script::cast(shared->script())); in TraceInlinedFunction()
271 os << "--- FUNCTION SOURCE (" << shared->DebugName()->ToCString().get() in TraceInlinedFunction()
275 int start = shared->start_position(); in TraceInlinedFunction()
276 int len = shared->end_position() - start; in TraceInlinedFunction()
293 os << "INLINE (" << shared->DebugName()->ToCString().get() << ") id{" in TraceInlinedFunction()
666 int opt_count = function->shared()->opt_count(); in RecordOptimizationStats()
667 function->shared()->set_opt_count(opt_count + 1); in RecordOptimizationStats()
685 code_size += function->shared()->SourceSize(); in RecordOptimizationStats()
700 void SetExpectedNofPropertiesFromEstimate(Handle<SharedFunctionInfo> shared, in SetExpectedNofPropertiesFromEstimate() argument
709 if (shared->GetIsolate()->serializer_enabled()) { in SetExpectedNofPropertiesFromEstimate()
717 shared->set_expected_nof_properties(estimate); in SetExpectedNofPropertiesFromEstimate()
731 Handle<SharedFunctionInfo> shared) { in RecordFunctionCompilation() argument
745 int line_num = Script::GetLineNumber(script, shared->start_position()) + 1; in RecordFunctionCompilation()
747 Script::GetColumnNumber(script, shared->start_position()) + 1; in RecordFunctionCompilation()
753 CodeCreateEvent(log_tag, *code, *shared, info, script_name, in RecordFunctionCompilation()
835 Handle<SharedFunctionInfo> shared = info->shared_info(); in GetUnoptimizedCodeCommon() local
837 DCHECK_EQ(shared->language_mode(), lit->language_mode()); in GetUnoptimizedCodeCommon()
838 SetExpectedNofPropertiesFromEstimate(shared, lit->expected_property_count()); in GetUnoptimizedCodeCommon()
839 MaybeDisableOptimization(shared, lit->dont_optimize_reason()); in GetUnoptimizedCodeCommon()
844 RecordFunctionCompilation(Logger::LAZY_COMPILE_TAG, info, shared); in GetUnoptimizedCodeCommon()
851 shared->set_scope_info(*scope_info); in GetUnoptimizedCodeCommon()
854 shared->ReplaceCode(*info->code()); in GetUnoptimizedCodeCommon()
855 shared->set_feedback_vector(*info->feedback_vector()); in GetUnoptimizedCodeCommon()
857 DCHECK(shared->function_data()->IsUndefined()); in GetUnoptimizedCodeCommon()
858 shared->set_function_data(*info->bytecode_array()); in GetUnoptimizedCodeCommon()
867 Handle<SharedFunctionInfo> shared(function->shared()); in GetCodeFromOptimizedCodeMap() local
869 CodeAndLiterals cached = shared->SearchOptimizedCodeMap( in GetCodeFromOptimizedCodeMap()
875 DCHECK(function->shared()->is_compiled()); in GetCodeFromOptimizedCodeMap()
894 Handle<SharedFunctionInfo> shared(function->shared()); in InsertCodeIntoOptimizedCodeMap() local
897 SharedFunctionInfo::AddToOptimizedCodeMap(shared, native_context, code, in InsertCodeIntoOptimizedCodeMap()
908 Handle<SharedFunctionInfo> shared(function->shared()); in InsertCodeIntoOptimizedCodeMap() local
909 SharedFunctionInfo::AddSharedCodeToOptimizedCodeMap(shared, code); in InsertCodeIntoOptimizedCodeMap()
1019 if (function->shared()->is_compiled()) { in GetUnoptimizedCode()
1020 return Handle<Code>(function->shared()->code()); in GetUnoptimizedCode()
1039 if (FLAG_turbo_asm && function->shared()->asm_function() && in GetLazyCode()
1047 info.SetOptimizing(BailoutId::None(), handle(function->shared()->code())); in GetLazyCode()
1050 DCHECK(function->shared()->is_compiled()); in GetLazyCode()
1058 if (function->shared()->is_compiled()) { in GetLazyCode()
1059 return Handle<Code>(function->shared()->code()); in GetLazyCode()
1101 Handle<SharedFunctionInfo> shared = info->shared_info(); in EnsureDeoptimizationSupport() local
1102 if (!shared->has_deoptimization_support()) { in EnsureDeoptimizationSupport()
1115 if (shared->code()->kind() == Code::FUNCTION && in EnsureDeoptimizationSupport()
1116 shared->code()->has_reloc_info_for_serialization()) { in EnsureDeoptimizationSupport()
1121 shared->EnableDeoptimizationSupport(*unoptimized.code()); in EnsureDeoptimizationSupport()
1122 shared->set_feedback_vector(*unoptimized.feedback_vector()); in EnsureDeoptimizationSupport()
1128 if (shared->scope_info() == ScopeInfo::Empty(info->isolate())) { in EnsureDeoptimizationSupport()
1131 shared->set_scope_info(*target_scope_info); in EnsureDeoptimizationSupport()
1135 RecordFunctionCompilation(Logger::LAZY_COMPILE_TAG, &unoptimized, shared); in EnsureDeoptimizationSupport()
1142 Handle<SharedFunctionInfo> shared) { in CompileEvalForDebugging() argument
1143 Handle<Script> script(Script::cast(shared->script())); in CompileEvalForDebugging()
1156 parse_info.set_language_mode(shared->language_mode()); in CompileEvalForDebugging()
1174 shared->ReplaceCode(*info.code()); in CompileEvalForDebugging()
1189 static inline bool IsEvalToplevel(Handle<SharedFunctionInfo> shared) { in IsEvalToplevel() argument
1190 return shared->is_toplevel() && shared->script()->IsScript() && in IsEvalToplevel()
1191 Script::cast(shared->script())->compilation_type() == in IsEvalToplevel()
1197 Handle<SharedFunctionInfo> shared(function->shared()); in CompileDebugCode() local
1198 if (IsEvalToplevel(shared)) { in CompileDebugCode()
1199 return CompileEvalForDebugging(function, shared); in CompileDebugCode()
1207 bool Compiler::CompileDebugCode(Handle<SharedFunctionInfo> shared) { in CompileDebugCode() argument
1208 DCHECK(shared->allows_lazy_compilation_without_context()); in CompileDebugCode()
1209 DCHECK(!IsEvalToplevel(shared)); in CompileDebugCode()
1211 ParseInfo parse_info(&zone, shared); in CompileDebugCode()
1710 Handle<SharedFunctionInfo> shared(function->shared(), isolate); in GetOptimizedCode() local
1711 if (shared->HasDebugInfo()) return MaybeHandle<Code>(); in GetOptimizedCode()
1729 if (!shared->is_compiled() || in GetOptimizedCode()
1730 shared->scope_info() == ScopeInfo::Empty(isolate)) { in GetOptimizedCode()
1738 shared->ReplaceCode(*current_code); in GetOptimizedCode()
1745 if (shared->disable_optimization_reason() == kEval) { in GetOptimizedCode()
1751 if (shared->is_toplevel() && isolate->bootstrapper()->IsActive()) { in GetOptimizedCode()
1787 Handle<SharedFunctionInfo> shared = info->shared_info(); in GetConcurrentlyOptimizedCode() local
1788 shared->code()->set_profiler_ticks(0); in GetConcurrentlyOptimizedCode()
1790 DCHECK(!shared->HasDebugInfo()); in GetConcurrentlyOptimizedCode()
1798 if (shared->optimization_disabled()) { in GetConcurrentlyOptimizedCode()
1803 RecordFunctionCompilation(Logger::LAZY_COMPILE_TAG, info.get(), shared); in GetConcurrentlyOptimizedCode()
1804 if (shared->SearchOptimizedCodeMap(info->context()->native_context(), in GetConcurrentlyOptimizedCode()