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

Side by Side Diff: runtime/include/dart_tools_api.h

Issue 1849643002: Add support for async, metadata, and counter timeline events to be reported by the embedder (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 | « no previous file | runtime/vm/dart_api_impl.cc » ('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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 #ifndef INCLUDE_DART_TOOLS_API_H_ 5 #ifndef INCLUDE_DART_TOOLS_API_H_
6 #define INCLUDE_DART_TOOLS_API_H_ 6 #define INCLUDE_DART_TOOLS_API_H_
7 7
8 #include "include/dart_api.h" 8 #include "include/dart_api.h"
9 9
10 /** \mainpage Dart Tools Embedding API Reference 10 /** \mainpage Dart Tools Embedding API Reference
(...skipping 965 matching lines...) Expand 10 before | Expand all | Expand 10 after
976 * \param user_data User data passed into consumer. 976 * \param user_data User data passed into consumer.
977 * 977 *
978 * NOTE: The trace-event format is documented here: https://goo.gl/hDZw5M 978 * NOTE: The trace-event format is documented here: https://goo.gl/hDZw5M
979 * 979 *
980 * \return True if a stream was output. 980 * \return True if a stream was output.
981 */ 981 */
982 DART_EXPORT bool Dart_GlobalTimelineGetTrace(Dart_StreamConsumer consumer, 982 DART_EXPORT bool Dart_GlobalTimelineGetTrace(Dart_StreamConsumer consumer,
983 void* user_data); 983 void* user_data);
984 984
985 typedef enum { 985 typedef enum {
986 Dart_Timeline_Event_Begin, // Phase = 'B'. 986 Dart_Timeline_Event_Begin, // Phase = 'B'.
987 Dart_Timeline_Event_End, // Phase = 'E'. 987 Dart_Timeline_Event_End, // Phase = 'E'.
988 Dart_Timeline_Event_Instant, // Phase = 'i'. 988 Dart_Timeline_Event_Instant, // Phase = 'i'.
989 Dart_Timeline_Event_Duration, // Phase = 'X'. 989 Dart_Timeline_Event_Duration, // Phase = 'X'.
990 Dart_Timeline_Event_Async_Begin, // Phase = 'b'.
991 Dart_Timeline_Event_Async_End, // Phase = 'e'.
992 Dart_Timeline_Event_Async_Instant, // Phase = 'n'.
993 Dart_Timeline_Event_Counter, // Phase = 'C'.
994 Dart_Timeline_Event_Metadata, // Phase = 'M'.
990 } Dart_Timeline_Event_Type; 995 } Dart_Timeline_Event_Type;
991 996
992 /** 997 /**
993 * Add a timeline event to the embedder stream. 998 * Add a timeline event to the embedder stream.
994 * 999 *
995 * \param label The name of the evnet. 1000 * \param label The name of the evnet.
996 * \param timestamp0 The first timestamp of the event. 1001 * \param timestamp0 The first timestamp of the event.
997 * \param timestamp1_or_async_id The second timestamp of the event or 1002 * \param timestamp1_or_async_id The second timestamp of the event or
998 * the async id. 1003 * the async id.
999 * \param argument_count The number of argument names and values. 1004 * \param argument_count The number of argument names and values.
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
1088 * \param start_recording See Dart_EmbedderTimelineStartRecording. 1093 * \param start_recording See Dart_EmbedderTimelineStartRecording.
1089 * \param stop_recording See Dart_EmbedderTimelineStopRecording. 1094 * \param stop_recording See Dart_EmbedderTimelineStopRecording.
1090 * 1095 *
1091 * NOTE: To avoid races, this should be called before Dart_Initialize. 1096 * NOTE: To avoid races, this should be called before Dart_Initialize.
1092 */ 1097 */
1093 DART_EXPORT void Dart_SetEmbedderTimelineCallbacks( 1098 DART_EXPORT void Dart_SetEmbedderTimelineCallbacks(
1094 Dart_EmbedderTimelineStartRecording start_recording, 1099 Dart_EmbedderTimelineStartRecording start_recording,
1095 Dart_EmbedderTimelineStopRecording stop_recording); 1100 Dart_EmbedderTimelineStopRecording stop_recording);
1096 1101
1097 #endif // INCLUDE_DART_TOOLS_API_H_ 1102 #endif // INCLUDE_DART_TOOLS_API_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/dart_api_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698