OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/compiler/wasm-compiler.h" | 5 #include "src/compiler/wasm-compiler.h" |
6 | 6 |
7 #include "src/isolate-inl.h" | 7 #include "src/isolate-inl.h" |
8 | 8 |
9 #include "src/base/platform/elapsed-timer.h" | 9 #include "src/base/platform/elapsed-timer.h" |
10 #include "src/base/platform/platform.h" | 10 #include "src/base/platform/platform.h" |
(...skipping 2479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2490 if (!code.is_null()) { | 2490 if (!code.is_null()) { |
2491 RecordFunctionCompilation(Logger::FUNCTION_TAG, &info, "WASM_function", | 2491 RecordFunctionCompilation(Logger::FUNCTION_TAG, &info, "WASM_function", |
2492 function.func_index, | 2492 function.func_index, |
2493 module_env->module->GetName( | 2493 module_env->module->GetName( |
2494 function.name_offset, function.name_length)); | 2494 function.name_offset, function.name_length)); |
2495 } | 2495 } |
2496 | 2496 |
2497 if (FLAG_trace_wasm_decode_time) { | 2497 if (FLAG_trace_wasm_decode_time) { |
2498 double compile_ms = compile_timer.Elapsed().InMillisecondsF(); | 2498 double compile_ms = compile_timer.Elapsed().InMillisecondsF(); |
2499 PrintF( | 2499 PrintF( |
2500 "wasm-compile ok: %d bytes, %0.3f ms decode, %0.3f ms compile\n", | 2500 "wasm-compile ok: %d bytes, %0.3f ms decode, %d nodes, %0.3f ms " |
| 2501 "compile\n", |
2501 static_cast<int>(function.code_end_offset - function.code_start_offset), | 2502 static_cast<int>(function.code_end_offset - function.code_start_offset), |
2502 decode_ms, compile_ms); | 2503 decode_ms, static_cast<int>(graph.NodeCount()), compile_ms); |
2503 } | 2504 } |
2504 return code; | 2505 return code; |
2505 } | 2506 } |
2506 | 2507 |
2507 | 2508 |
2508 } // namespace compiler | 2509 } // namespace compiler |
2509 } // namespace internal | 2510 } // namespace internal |
2510 } // namespace v8 | 2511 } // namespace v8 |
OLD | NEW |