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

Unified Diff: runtime/vm/dart_api_impl.cc

Issue 1848683002: Remove redundant timeline API (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/include/dart_tools_api.h ('k') | runtime/vm/dart_api_impl_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/dart_api_impl.cc
diff --git a/runtime/vm/dart_api_impl.cc b/runtime/vm/dart_api_impl.cc
index ffcbc7da62e066a7ebdc1af8cc8c074e88f3ad1a..0a25473aabd089d59f48d3d6d40b86d9fbbdada3 100644
--- a/runtime/vm/dart_api_impl.cc
+++ b/runtime/vm/dart_api_impl.cc
@@ -6006,115 +6006,6 @@ DART_EXPORT void Dart_TimelineEvent(const char* label,
}
-DART_EXPORT void Dart_TimelineDuration(const char* label,
- int64_t start_micros,
- int64_t end_micros) {
- if (!FLAG_support_timeline) {
- return;
- }
- if (start_micros > end_micros) {
- FATAL1("%s: start_micros must be <= end_micros", CURRENT_FUNC);
- }
- if (label == NULL) {
- return;
- }
- TimelineStream* stream = Timeline::GetEmbedderStream();
- ASSERT(stream != NULL);
- TimelineEvent* event = stream->StartEvent();
- if (event != NULL) {
- event->Duration(label, start_micros, end_micros);
- event->Complete();
- }
-}
-
-
-DART_EXPORT void Dart_TimelineInstant(const char* label) {
- if (!FLAG_support_timeline) {
- return;
- }
- if (label == NULL) {
- return;
- }
- TimelineStream* stream = Timeline::GetEmbedderStream();
- ASSERT(stream != NULL);
- TimelineEvent* event = stream->StartEvent();
- if (event != NULL) {
- event->Instant(label);
- event->Complete();
- }
- return;
-}
-
-
-DART_EXPORT void Dart_TimelineAsyncBegin(const char* label,
- int64_t* async_id) {
- if (!FLAG_support_timeline) {
- return;
- }
- if (label == NULL) {
- return;
- }
- if (async_id == NULL) {
- return;
- }
- *async_id = -1;
- TimelineStream* stream = Timeline::GetEmbedderStream();
- ASSERT(stream != NULL);
- TimelineEvent* event = stream->StartEvent();
- if (event != NULL) {
- TimelineEventRecorder* recorder = Timeline::recorder();
- ASSERT(recorder != NULL);
- *async_id = recorder->GetNextAsyncId();
- event->AsyncBegin(label, *async_id);
- event->Complete();
- }
- return;
-}
-
-
-DART_EXPORT void Dart_TimelineAsyncInstant(const char* label,
- int64_t async_id) {
- if (!FLAG_support_timeline) {
- return;
- }
- if (async_id < 0) {
- return;
- }
- if (label == NULL) {
- return;
- }
- TimelineStream* stream = Timeline::GetEmbedderStream();
- ASSERT(stream != NULL);
- TimelineEvent* event = stream->StartEvent();
- if (event != NULL) {
- event->AsyncInstant(label, async_id);
- event->Complete();
- }
- return;
-}
-
-
-DART_EXPORT void Dart_TimelineAsyncEnd(const char* label,
- int64_t async_id) {
- if (!FLAG_support_timeline) {
- return;
- }
- if (async_id < 0) {
- return;
- }
- if (label == NULL) {
- return;
- }
- TimelineStream* stream = Timeline::GetEmbedderStream();
- ASSERT(stream != NULL);
- TimelineEvent* event = stream->StartEvent();
- if (event != NULL) {
- event->AsyncEnd(label, async_id);
- event->Complete();
- }
- return;
-}
-
// The precompiler is included in dart_bootstrap and dart_noopt, and
// excluded from dart and dart_precompiled_runtime.
#if !defined(DART_PRECOMPILER)
« no previous file with comments | « runtime/include/dart_tools_api.h ('k') | runtime/vm/dart_api_impl_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698