Commit 8ba35e73 authored by mstarzinger's avatar mstarzinger Committed by Commit bot

[compiler] Remove redundant unoptimized compile trigger.

The trigger point in question is by now obsolete. The optimized compile
job will itself ensure that deoptimization support is present on the
incoming SharedFunctionInfo, this will make sure to produce baseline
code when necessary. The ScopeInfo is also installed at that point in
time.

R=yangguo@chromium.org

Review URL: https://codereview.chromium.org/1816513002

Cr-Commit-Position: refs/heads/master@{#34887}
parent 2bc32f22
...@@ -1096,21 +1096,10 @@ MaybeHandle<Code> GetOptimizedCode(Handle<JSFunction> function, ...@@ -1096,21 +1096,10 @@ MaybeHandle<Code> GetOptimizedCode(Handle<JSFunction> function,
DCHECK(AllowCompilation::IsAllowed(isolate)); DCHECK(AllowCompilation::IsAllowed(isolate));
if (!shared->is_compiled() || if (shared->is_compiled()) {
shared->scope_info() == ScopeInfo::Empty(isolate)) { shared->code()->set_profiler_ticks(0);
// The function was never compiled. Compile it unoptimized first.
// TODO(titzer): reuse the AST and scope info from this compile.
CompilationInfoWithZone unoptimized(function);
unoptimized.EnableDeoptimizationSupport();
Handle<Code> unoptimized_code;
if (!GetUnoptimizedCodeCommon(&unoptimized).ToHandle(&unoptimized_code)) {
return MaybeHandle<Code>();
}
shared->ReplaceCode(*unoptimized_code);
} }
shared->code()->set_profiler_ticks(0);
// TODO(mstarzinger): We cannot properly deserialize a scope chain containing // TODO(mstarzinger): We cannot properly deserialize a scope chain containing
// an eval scope and hence would fail at parsing the eval source again. // an eval scope and hence would fail at parsing the eval source again.
if (shared->disable_optimization_reason() == kEval) { if (shared->disable_optimization_reason() == kEval) {
......
...@@ -497,10 +497,6 @@ ...@@ -497,10 +497,6 @@
'test-run-jsexceptions/ThrowMessagePosition': [FAIL], 'test-run-jsexceptions/ThrowMessagePosition': [FAIL],
'test-api/TryCatchMixedNesting': [FAIL], 'test-api/TryCatchMixedNesting': [FAIL],
# TODO(rmcilroy,4766): Requires BytecodeGraphBuilder to track source position
# on nodes (behind --turbo_source_positions flag).
'test-cpu-profiler/TickLinesOptimized': [FAIL],
# TODO(mythria,4780): Related to type feedback support for calls. # TODO(mythria,4780): Related to type feedback support for calls.
'test-feedback-vector/VectorCallICStates': [FAIL], 'test-feedback-vector/VectorCallICStates': [FAIL],
'test-compiler/FeedbackVectorPreservedAcrossRecompiles': [FAIL], 'test-compiler/FeedbackVectorPreservedAcrossRecompiles': [FAIL],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment