[Compiler] Extend stress source positions for eager inner functions.

Extend stress source positions to also ensure source positions for eagerly
compiled inner functions when lazily compiling the outer function.

BUG=v8:8510

Change-Id: I66d04beb789f13c15ed87cf10f606723c18f5d8f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1774725
Commit-Queue: Dan Elphick <delphick@chromium.org>
Auto-Submit: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#63482}
This commit is contained in:
Ross McIlroy 2019-08-28 21:29:19 +01:00 committed by Commit Bot
parent 1884223839
commit 286590504d

View File

@ -1349,6 +1349,16 @@ bool Compiler::Compile(Handle<SharedFunctionInfo> shared_info,
// Collect source positions immediately to try and flush out bytecode
// mismatches.
SharedFunctionInfo::EnsureSourcePositionsAvailable(isolate, shared_info);
// Do the same for eagerly compiled inner functions.
for (auto&& inner_job : inner_function_jobs) {
Handle<SharedFunctionInfo> inner_shared_info =
Compiler::GetSharedFunctionInfo(
inner_job->compilation_info()->literal(), parse_info.script(),
isolate);
SharedFunctionInfo::EnsureSourcePositionsAvailable(isolate,
inner_shared_info);
}
}
return true;