Commit d7369a97 authored by Stephan Herhut's avatar Stephan Herhut Committed by Commit Bot

[cleanup] Log compilation start/end for wasm

As the wasm compilation pipeline skips the start and end phase of
normal pipelines, we do not log compilation start/end for functions,
which makes reading log output more complicated than need be.

Change-Id: I1566ab7428b2dd9763c443000e946d4c6c789626
Reviewed-on: https://chromium-review.googlesource.com/c/1304540Reviewed-by: 's avatarMichael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Stephan Herhut <herhut@chromium.org>
Cr-Commit-Position: refs/heads/master@{#57093}
parent 00a2e858
......@@ -1048,6 +1048,15 @@ PipelineWasmCompilationJob::Status PipelineWasmCompilationJob::PrepareJobImpl(
PipelineWasmCompilationJob::Status
PipelineWasmCompilationJob::ExecuteJobImpl() {
if (data_.info()->trace_turbo_json_enabled() ||
data_.info()->trace_turbo_graph_enabled()) {
CodeTracer::Scope tracing_scope(data_.GetCodeTracer());
OFStream os(tracing_scope.file());
os << "---------------------------------------------------\n"
<< "Begin compiling method " << data_.info()->GetDebugName().get()
<< " using Turbofan" << std::endl;
}
pipeline_.RunPrintAndVerify("Machine", true);
PipelineData* data = &data_;
......@@ -1120,6 +1129,15 @@ PipelineWasmCompilationJob::ExecuteJobImpl() {
compilation_info()->SetCode(code);
if (data_.info()->trace_turbo_json_enabled() ||
data_.info()->trace_turbo_graph_enabled()) {
CodeTracer::Scope tracing_scope(data->GetCodeTracer());
OFStream os(tracing_scope.file());
os << "---------------------------------------------------\n"
<< "Finished compiling method " << data_.info()->GetDebugName().get()
<< " using Turbofan" << std::endl;
}
return SUCCEEDED;
}
......@@ -2226,6 +2244,15 @@ MaybeHandle<Code> Pipeline::GenerateCodeForWasmStub(
PipelineImpl pipeline(&data);
if (info.trace_turbo_json_enabled() ||
info.trace_turbo_graph_enabled()) {
CodeTracer::Scope tracing_scope(data.GetCodeTracer());
OFStream os(tracing_scope.file());
os << "---------------------------------------------------\n"
<< "Begin compiling method " << info.GetDebugName().get()
<< " using Turbofan" << std::endl;
}
if (info.trace_turbo_graph_enabled()) { // Simple textual RPO.
StdoutStream{} << "-- wasm stub " << Code::Kind2String(kind) << " graph -- "
<< std::endl
......
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