Commit ba6f813c authored by Maya Lekova's avatar Maya Lekova Committed by Commit Bot

[turbofan] Remove unnecessary call to Compiler::Compile from JSInliner

Introduced a CHECK instead and details about the invariant it relies on.

R=neis@chromium.org, rmcilroy@chromium.org

Change-Id: I568fc6d737c6bf70bd7aabf47df22651e3fcf8fc
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1517882Reviewed-by: 's avatarGeorg Neis <neis@chromium.org>
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/master@{#60234}
parent 7271e97f
...@@ -435,14 +435,11 @@ Reduction JSInliner::ReduceJSCall(Node* node) { ...@@ -435,14 +435,11 @@ Reduction JSInliner::ReduceJSCall(Node* node) {
} }
IsCompiledScope is_compiled_scope(shared_info->is_compiled_scope()); IsCompiledScope is_compiled_scope(shared_info->is_compiled_scope());
if (!is_compiled_scope.is_compiled() && // JSInliningHeuristic should have already filtered candidates without
!Compiler::Compile(shared_info, Compiler::CLEAR_EXCEPTION, // a BytecodeArray by calling SharedFunctionInfo::IsInlineable. For the ones
&is_compiled_scope)) { // passing the check, a reference to the bytecode was retained to make sure
TRACE("Not inlining %s into %s because bytecode generation failed\n", // it never gets flushed, so the following check should always hold true.
shared_info->DebugName()->ToCString().get(), CHECK(is_compiled_scope.is_compiled());
info_->shared_info()->DebugName()->ToCString().get());
return NoChange();
}
if (info_->is_source_positions_enabled()) { if (info_->is_source_positions_enabled()) {
SharedFunctionInfo::EnsureSourcePositionsAvailable(isolate(), shared_info); SharedFunctionInfo::EnsureSourcePositionsAvailable(isolate(), shared_info);
......
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