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

Unified Diff: runtime/lib/timeline.cc

Issue 1985813002: Add an intrinsified early out path for Dart timeline calls (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 7 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 | « no previous file | runtime/lib/timeline.dart » ('j') | runtime/vm/intrinsifier_arm.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/timeline.cc
diff --git a/runtime/lib/timeline.cc b/runtime/lib/timeline.cc
index d8bef457202901fbf7c4ac1b5f7bc84760635924..b5b397db5ee0ae40cae014ee6ce6d81c547084ce 100644
--- a/runtime/lib/timeline.cc
+++ b/runtime/lib/timeline.cc
@@ -15,6 +15,17 @@ namespace dart {
// Native implementations for the dart:developer library.
+DEFINE_NATIVE_ENTRY(Timeline_isDartStreamEnabled, 0) {
+ if (!FLAG_support_timeline) {
+ return Bool::False().raw();
+ }
+ if (Timeline::GetDartStream()->enabled()) {
+ return Bool::True().raw();
+ }
+ return Bool::False().raw();
+}
+
+
DEFINE_NATIVE_ENTRY(Timeline_getIsolateNum, 0) {
return Integer::New(static_cast<int64_t>(isolate->main_port()), Heap::kOld);
}
« no previous file with comments | « no previous file | runtime/lib/timeline.dart » ('j') | runtime/vm/intrinsifier_arm.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698