Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(162)

Side by Side Diff: runtime/bin/main.cc

Issue 1848683002: Remove redundant timeline API (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/bin/isolate_data.h ('k') | runtime/include/dart_tools_api.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include <stdlib.h> 5 #include <stdlib.h>
6 #include <string.h> 6 #include <string.h>
7 #include <stdio.h> 7 #include <stdio.h>
8 8
9 #include "include/dart_api.h" 9 #include "include/dart_api.h"
10 #include "include/dart_tools_api.h" 10 #include "include/dart_tools_api.h"
(...skipping 822 matching lines...) Expand 10 before | Expand all | Expand 10 after
833 833
834 if (!run_precompiled_snapshot && !run_full_snapshot) { 834 if (!run_precompiled_snapshot && !run_full_snapshot) {
835 // Load the specified application script into the newly created isolate. 835 // Load the specified application script into the newly created isolate.
836 result = DartUtils::LoadScript(script_uri); 836 result = DartUtils::LoadScript(script_uri);
837 CHECK_RESULT(result); 837 CHECK_RESULT(result);
838 838
839 // Run event-loop and wait for script loading to complete. 839 // Run event-loop and wait for script loading to complete.
840 result = Dart_RunLoop(); 840 result = Dart_RunLoop();
841 CHECK_RESULT(result); 841 CHECK_RESULT(result);
842 842
843 if (isolate_data->load_async_id >= 0) { 843 Dart_TimelineEvent("LoadScript",
844 Dart_TimelineAsyncEnd("LoadScript", isolate_data->load_async_id); 844 Dart_TimelineGetMicros(),
845 } 845 Dart_GetMainPortId(),
846 Dart_Timeline_Event_Async_End,
847 0, NULL, NULL);
846 848
847 result = DartUtils::SetupIOLibrary(script_uri); 849 result = DartUtils::SetupIOLibrary(script_uri);
848 CHECK_RESULT(result); 850 CHECK_RESULT(result);
849 } else if (run_full_snapshot) { 851 } else if (run_full_snapshot) {
850 result = DartUtils::SetupIOLibrary(script_uri); 852 result = DartUtils::SetupIOLibrary(script_uri);
851 CHECK_RESULT(result); 853 CHECK_RESULT(result);
852 } 854 }
853 855
854 // Make the isolate runnable so that it is ready to handle messages. 856 // Make the isolate runnable so that it is ready to handle messages.
855 Dart_ExitScope(); 857 Dart_ExitScope();
(...skipping 846 matching lines...) Expand 10 before | Expand all | Expand 10 after
1702 Platform::Exit(Process::GlobalExitCode()); 1704 Platform::Exit(Process::GlobalExitCode());
1703 } 1705 }
1704 1706
1705 } // namespace bin 1707 } // namespace bin
1706 } // namespace dart 1708 } // namespace dart
1707 1709
1708 int main(int argc, char** argv) { 1710 int main(int argc, char** argv) {
1709 dart::bin::main(argc, argv); 1711 dart::bin::main(argc, argv);
1710 UNREACHABLE(); 1712 UNREACHABLE();
1711 } 1713 }
OLDNEW
« no previous file with comments | « runtime/bin/isolate_data.h ('k') | runtime/include/dart_tools_api.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698