diff --git a/runtime/docs/timeline.md b/runtime/docs/timeline.md index dbab9706e36..bed61056c3e 100644 --- a/runtime/docs/timeline.md +++ b/runtime/docs/timeline.md @@ -30,7 +30,7 @@ Streams, also called categories, are sets of events whose recordering can be ena | `CompilerVerbose` | Events for detailed compiler phases. | | `Dart` | Events created by `dart:developer`'s `Timeline` etc. | | `Debugger` | | -| `Embedder` | Events created by `Dart_TimelineEvent`. | +| `Embedder` | Events created by `Dart_RecordTimelineEvent`. | | `GC` | Events related to garbage collection or heap iteration. | | `Isolate` | Isolate or isolate group lifecycle events such as startup or shutdown. | | `VM` | VM lifecycle events such a startup or shutdown. | diff --git a/runtime/include/dart_tools_api.h b/runtime/include/dart_tools_api.h index 7b706bc977d..77bc4085702 100644 --- a/runtime/include/dart_tools_api.h +++ b/runtime/include/dart_tools_api.h @@ -353,44 +353,6 @@ typedef enum { Dart_Timeline_Event_Flow_End, // Phase = 'f'. } Dart_Timeline_Event_Type; -/** - * Add a timeline event to the embedder stream. - * - * DEPRECATED: this function will be removed in Dart SDK v3.2. - * - * \param label The name of the event. Its lifetime must extend at least until - * Dart_Cleanup. - * \param timestamp0 The first timestamp of the event. - * \param timestamp1_or_id When reporting an event of type - * |Dart_Timeline_Event_Duration|, the second (end) timestamp of the event - * should be passed through |timestamp1_or_id|. When reporting an event of - * type |Dart_Timeline_Event_Async_Begin|, |Dart_Timeline_Event_Async_End|, - * or |Dart_Timeline_Event_Async_Instant|, the async ID associated with the - * event should be passed through |timestamp1_or_id|. When reporting an - * event of type |Dart_Timeline_Event_Flow_Begin|, - * |Dart_Timeline_Event_Flow_Step|, or |Dart_Timeline_Event_Flow_End|, the - * flow ID associated with the event should be passed through - * |timestamp1_or_id|. When reporting an event of type - * |Dart_Timeline_Event_Begin| or |Dart_Timeline_Event_End|, the event ID - * associated with the event should be passed through |timestamp1_or_id|. - * Note that this event ID will only be used by the MacOS recorder. The - * argument to |timestamp1_or_id| will not be used when reporting events of - * other types. - * \param argument_count The number of argument names and values. - * \param argument_names An array of names of the arguments. The lifetime of the - * names must extend at least until Dart_Cleanup. The array may be reclaimed - * when this call returns. - * \param argument_values An array of values of the arguments. The values and - * the array may be reclaimed when this call returns. - */ -DART_EXPORT void Dart_TimelineEvent(const char* label, - int64_t timestamp0, - int64_t timestamp1_or_id, - Dart_Timeline_Event_Type type, - intptr_t argument_count, - const char** argument_names, - const char** argument_values); - /** * Add a timeline event to the embedder stream. * @@ -520,8 +482,8 @@ typedef void (*Dart_TimelineRecorderCallback)( * The callback will be invoked without a current isolate. * * The callback will be invoked on the thread completing the event. Because - * `Dart_TimelineEvent` may be called by any thread, the callback may be called - * on any thread. + * `Dart_RecordTimelineEvent` may be called by any thread, the callback may be + * called on any thread. * * The callback may be invoked at any time after `Dart_Initialize` is called and * before `Dart_Cleanup` returns. diff --git a/runtime/tests/vm/dart/exported_symbols_test.dart b/runtime/tests/vm/dart/exported_symbols_test.dart index d466fe341c0..fe5a693d5cb 100644 --- a/runtime/tests/vm/dart/exported_symbols_test.dart +++ b/runtime/tests/vm/dart/exported_symbols_test.dart @@ -337,7 +337,6 @@ main() { "Dart_ThreadDisableProfiling", "Dart_ThreadEnableProfiling", "Dart_ThrowException", - "Dart_TimelineEvent", "Dart_TimelineGetMicros", "Dart_TimelineGetTicks", "Dart_TimelineGetTicksFrequency", diff --git a/runtime/vm/dart_api_impl.cc b/runtime/vm/dart_api_impl.cc index 1076a708857..3d2e21904b7 100644 --- a/runtime/vm/dart_api_impl.cc +++ b/runtime/vm/dart_api_impl.cc @@ -6436,18 +6436,6 @@ DART_EXPORT int64_t Dart_TimelineGetTicksFrequency() { return OS::GetCurrentMonotonicFrequency(); } -DART_EXPORT void Dart_TimelineEvent(const char* label, - int64_t timestamp0, - int64_t timestamp1_or_id, - Dart_Timeline_Event_Type type, - intptr_t argument_count, - const char** argument_names, - const char** argument_values) { - Dart_RecordTimelineEvent(label, timestamp0, timestamp1_or_id, - /*flow_id_count=*/0, /*flow_ids=*/nullptr, type, - argument_count, argument_names, argument_values); -} - DART_EXPORT void Dart_RecordTimelineEvent(const char* label, int64_t timestamp0, int64_t timestamp1_or_id, diff --git a/runtime/vm/service.cc b/runtime/vm/service.cc index 452f9c12e0d..3c5593ea4f9 100644 --- a/runtime/vm/service.cc +++ b/runtime/vm/service.cc @@ -4734,7 +4734,7 @@ static intptr_t GetProcessMemoryUsageHelper(JSONStream* js) { timeline.AddProperty("name", "Timeline"); timeline.AddProperty( "description", - "Timeline events from dart:developer and Dart_TimelineEvent"); + "Timeline events from dart:developer and Dart_RecordTimelineEvent"); intptr_t size = Timeline::recorder()->Size(); vm_size += size; timeline.AddProperty64("size", size);